Center out the last point on the Chart

2 次查看(过去 30 天)
Dima
Dima 2012-3-18
Hello! I wonder if you think it can be possible to plot a time series in such a way that the plot focuses on the last data point - it is shown in the vertical centre of the chart? example dataset:
1 0.540302306
2 -0.416146837
3 -0.989992497
4 -0.653643621
5 0.283662185
6 0.960170287
7 0.753902254
8 -0.145500034
9 -0.911130262
10 -0.839071529
11 0.004425698
12 0.843853959
13 0.004425698
14 0.843853959
15 0.004425698
16 0.843853959
Thanks! Dima

回答(1 个)

Image Analyst
Image Analyst 2012-3-18
Please make it so that that is regular MATLAB code that we can run easily by copying and pasting.
You can use xlim() to set the range of your x axis, for example to have 16 in the middle of the x axis of the chart:
xlim([1 31]);

类别

Help CenterFile Exchange 中查找有关 Visual Exploration 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by