make plot in matrix data

조회 수: 6 (최근 30일)
il147
il147 2022년 2월 22일
댓글: KSSV 2022년 2월 22일
I have monthly data and would like to make plot annually
but my plot is weird like that
this is my code and I combine data and year
I'd like to make a plot with year (x)and data(y)
I have short english and matlab so sorry about awkward explain
Thanks
date=readtable(name3{2},'Range','A13:A23')
data=readtable(name3{2},'Range','B13:M23')
data=data{:,:}
date=date{:,:}
A=[date,data]
x=A(:,1)
y=A(:,2:end)
plot(x,y)
->monthly, ↓annual

채택된 답변

KSSV
KSSV 2022년 2월 22일
Try:
plot(x',y')
  댓글 수: 4
il147
il147 2022년 2월 22일
Does T mean data or date?
KSSV
KSSV 2022년 2월 22일
T is a table.

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 2-D and 3-D Plots에 대해 자세히 알아보기

태그

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by