フィルターのクリア

Changing X-Axis to Hours

1 回表示 (過去 30 日間)
Shelby Fabian
Shelby Fabian 2016 年 12 月 6 日
コメント済み: Shelby Fabian 2016 年 12 月 6 日
I am trying to plot a temperature function for 48 hours, but I want the axis to read "12:00 AM", "1:00 AM", "2:00 AM", etc. for the 2 day cycle. I've tried a bunch of things but I can't get it to actually add an hour each time and print them as the axis labels. Any suggestions? Thanks!

採用された回答

Preethi
Preethi 2016 年 12 月 6 日
hi,
You can use XTickLabel, for example
set(gca,'XTickLabel',{'1:00AM','2:00AM','3:00AM','4:00AM','5:00AM','6:00AM'})
  1 件のコメント
Shelby Fabian
Shelby Fabian 2016 年 12 月 6 日
Thank you so much!

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeDates and Time についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by