[GUI] How do change the min and max values of a plot.
3 次查看(过去 30 天)
显示 更早的评论
I want to change the min and max values of a plot in GUI.
And the following code doesn't work:
axis(handles.axes1,[0,100,0,1]);
This is because then when I plot a scatter after
scatter(handles.axes1, x, y);
It doesn't keep the same dimensions on the axes.
I then tried hold(handles.axes1);
between the two bits of code and it still doesn't work... confused.
What am I doing wrong?
0 个评论
回答(1 个)
Image Analyst
2012-12-19
Use the xlim() and ylim() functions.
7 个评论
Jan
2012-12-19
@Shane: Besides Walter's suggestion, what about calling XLIM after all plots have been made?
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Annotations 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!