필터 지우기
필터 지우기

How visualize data in matlab

조회 수: 2 (최근 30일)
Agnes Palit
Agnes Palit 2018년 7월 16일
댓글: Star Strider 2018년 7월 16일
I am trying to visualize data in matlab with this file (I have attach above).
How to visualize the data with the x-axis is the "date2", dan the y-axis is "mean_METs"?

채택된 답변

Star Strider
Star Strider 2018년 7월 16일
편집: Star Strider 2018년 7월 16일
With your data, use the structure field reference with your ‘ee_moderate’ table:
d = load('ee_moderate.mat');
ee_moderate = d.ee_moderate;
figure
plot(ee_moderate.date2, ee_moderate.mean_METs)
xlabel('date2')
ylabel('mean\_METs')
grid
  댓글 수: 4
Agnes Palit
Agnes Palit 2018년 7월 16일
Thank you very much for the idea.
Star Strider
Star Strider 2018년 7월 16일
As always, my pleasure.

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

추가 답변 (1개)

KARSH THARYANI
KARSH THARYANI 2018년 7월 16일
Hi,
Please follow the examples here
In short, you need to load your .mat file and the variables will show up in your workspace, if loaded successfully.
Then, you can plot them.
To plot, you can refer to some examples here
So, for instance if you have a column vector in X and the values corresponding to it in Y, you can do
plot(X, Y);

카테고리

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