change start point of plot

29 次查看(过去 30 天)
Hi how can I change the Jan to start at 0?

采纳的回答

Cris LaPierre
Cris LaPierre 2021-3-3
You can change the first point's y value from 105 to 0.
d=datetime(2020,1,1):calmonths:datetime(2020,12,1);
y = randi(160,[1,12])+100;
M = month(d,'shortname');
plot(categorical(M,M),y)
% change the first point to 0
y(1)=0;
plot(categorical(M,M),y)

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Scatter Plots 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by