another problem with subplot...

and the same question: this behavior is normal?

fig1 = figure()
ax1 = subplot(121)
xlim([0,10])
ax2 = subplot(122,sharey=ax1)
yticks([])

I would like to hide the ticks label for only one subplot (the one who share
the axes) but I would like to have the ticklabels for the global plot, ie on
the left subplot.

I was thinking that sharey means that the plot will have the same limit for
this axes not to have all the properties. Do I have to tell to all the
subplot to have the same limit and remove the ticks for the one I want?

N.

humufr@...136... wrote:

and the same question: this behavior is normal?

fig1 = figure()
ax1 = subplot(121)
xlim([0,10])
ax2 = subplot(122,sharey=ax1)
yticks([])

I would like to hide the ticks label for only one subplot (the one who share the axes) but I would like to have the ticklabels for the global plot, ie on the left subplot.

I was thinking that sharey means that the plot will have the same limit for this axes not to have all the properties. Do I have to tell to all the subplot to have the same limit and remove the ticks for the one I want?

The way axis sharing is implemented, everything is shared; a single axis object is used for more than one axes object. I agree that this is not always what one wants, but I think it would be quite difficult to change, so for now you will need to forgo the sharey kwarg and instead manually synchronize the properties that you want the axes to have in common. Unless John has a better idea, of course...

Eric