【发布时间】:2013-09-14 11:05:42
【问题描述】:
我在 Matlab 中有一个简单的绘图,但您可以从屏幕截图中看到。数据序列结束后,图表右侧有很多空白。
知道如何摆脱这个空白并使情节直接到图形的边缘吗?这是我的代码:
Plotx = plot(x);
hold on
PlotState = plot(Y);
set(Plotx,'Color','black','LineWidth',2.5);
set(PlotState,'Color','red','LineWidth',2.5);
set(gca, 'XTick',(1:3:62))
labels = time;
set(gca,'XTickLabel',labels(1:3:62))
grid on
【问题讨论】:
-
这个answer 展示了如何移除任意一侧的边框。