Plotting only one axis

31 次查看(过去 30 天)
Jetson Ronald
Jetson Ronald 2012-6-8
Hello I am having a plot and I don't want to use the axis off command to remove the information in both axes, but I want to have the information in the X-axis and want the Y-axis to be completely free. Kindly help me how to do that.

回答(2 个)

Aurelien Queffurust
I would use these commands:
plot(1:10)
set(gca,'ytick',[],'Ycolor','w','box','off')

Jessica Lam
Jessica Lam 2012-6-8
You may set the axis color same as the background color .
  1 个评论
Jessica Lam
Jessica Lam 2012-6-8
You may find the following code for your reference.
figure1=figure(1);
axes1 = axes('Parent',figure1,...
'YColor', get(figure1,'Color'));
hold(axes1,'all');
plot (1:10,'b');

请先登录,再进行评论。

类别

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

标签

Community Treasure Hunt

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

Start Hunting!

Translated by