|
From: Paul H. <pmh...@gm...> - 2013-05-15 23:20:11
|
On Wed, May 15, 2013 at 3:48 PM, gaspra <ye...@gm...> wrote:
> Hi, I am having troubles to correctly make a figure with inverted log axis.
> This is what I am doing:
>
> import numpy as np
> import matplotlib.pyplot as plt
>
> y=np.linspace(-90,90,20)
> z=np.arange(1,1.e4, 200)
>
> c=y.reshape(20,1)*z.reshape(1,len(z))
>
> fig,ax=plt.subplots()
> plt.pcolor(y,z,c.transpose())
> ax.set_yscale('log')
> ax.invert_yaxis()
>
> The problem is that the ticks of y axis is not displayed correctly once I
> invert the y axis. It shows the tick at 1000. All other ticks such as 100,
> 10 and 1 are missing. Am I doing something wrong or is this a bug in
> matplotlib?
>
> Thanks for your help.
>
This works fine on my system:
In [3]: np.version.full_version
Out[3]: '1.7.1'
In [5]: matplotlib.__version__
Out[5]: '1.2.1'
Not sure what the issue could be.
-p
|