フィルターのクリア

How to convert data points to time

11 ビュー (過去 30 日間)
Nurhidayah Zainol
Nurhidayah Zainol 2020 年 12 月 21 日
回答済み: Steven Lord 2020 年 12 月 22 日
Hi, so I have this data and I want to convert the x-axis to time. Right now the x-axis represents the data point. Please help.

採用された回答

Steven Lord
Steven Lord 2020 年 12 月 22 日
Make a datetime or duration array and call plot with that as the first data input.
v = 1:10;
x = datetime('today')+days(v);
y = v.^2;
plot(x, y)
t = hours(v);
plot(t, y)

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeDescriptive Statistics についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by