plot all dates to x-axis in bar graph

10 ビュー (過去 30 日間)
MakM
MakM 2022 年 11 月 10 日
回答済み: Cris LaPierre 2022 年 11 月 10 日
d = datetime(2017,1:20,1);
x = rand(1,20);
bar(d,x)
I have this code, I want all the 20 dates to be visible on the x axis, but only 4 months are visible, what can I add in the code to get all the dates on the x-axis.

採用された回答

Cris LaPierre
Cris LaPierre 2022 年 11 月 10 日
d = datetime(2017,1:20,1);
x = rand(1,20);
bar(d,x)
xticks(d)

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeBar Plots についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by