Yaxis invisible

2 visualizaciones (últimos 30 días)
Ian
Ian el 28 de En. de 2011
I would like to make the yaxis invisible without getting rid of the text.
'axis off' is no good, because that gets rid of the ylabel, which I would like to keep.
I have tried:
set(gca,'box','off','ycolor','w')
but this also turns the text color to white.
In the end effect, I just don't want a black outline around my plots to be shown.
I have tried 'box off' but that doesnt seem to get rid of the black outline around my plots or subplots.

Respuestas (1)

Matt Fig
Matt Fig el 28 de En. de 2011
I don't think there is a way of doing it directly. Here is a hackey way of getting what you want for the Y-axis. Do similar for the other axis.
plot(1:10)
X = get(gca,'xlim')
xlim(X)
Y = get(gca,'ylim')
ylim(Y)
P = patch([X(1)-.05 X(1)-.05 X(1)+.1 X(1)+.1],[Y(1) Y(2) Y(2) Y(1)],...
[1 1 1 1],[1 1 1],'edgecolor',[1 1 1])
box off

Categorías

Más información sobre Surface and Mesh Plots en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by