DOES ANYONE KNOW HOW CAN INSERT AND PLOT THIS DATA AS POINTS?

Hello everyone,
when I go to plot the column 11 of the table "Data" any point appears in my graph.
Data of column 11 should be related to their years as in the table.
plot(T.Year(:,1),[NEW, T.Var4(:,1) DATA.SMB_mp_mm(:,1)],'g');
Could anyone help me kindly?
Thank you!

 채택된 답변

Walter Roberson
Walter Roberson 2021년 7월 21일
You need
plot(T.Year(:,1),[NEW, T.Var4(:,1) DATIMARannuali.SMB_mp_mm(:,1)],'g');
However, your other variables have 7721 rows, but SMB_mp_mm only has 40 rows, so it is not clear what you would want to plot.

댓글 수: 3

Pul
Pul 2021년 7월 22일
편집: Pul 2021년 7월 22일
Yes I know.
I need to plot on the 1st January 1979 the data related to the first SMB_mp_mm value, the 1st January 1980 data related to the second first SMB_mp_mm value and so on, until the end.
I know the table 40x13 starts from 1979 while the table of 7221 starts from 1997.
However, I tried to put manually the values, adding a new column in the table with 7221 rows (even if it takes so much time) but I couldn't see the point on my graph.
Change to
plot(T.Year(:,1),[NEW, T.Var4(:,1)], 'g', datetime(DATIMARannuali.Year,1,1), DATIMARannuali.SMB_mp_mm,'k-*');
hold off
Thank you.

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

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 2-D and 3-D Plots에 대해 자세히 알아보기

질문:

Pul
2021년 7월 21일

댓글:

Pul
2021년 7월 23일

Community Treasure Hunt

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

Start Hunting!

Translated by