On Jul 30, 2010, at 14:34, Nikolaus Rath <nikol...@rath.org> wrote:

> Hi,
> 
> Consider this:
> 
> X = np.linspace(0.70, 1.1, 100)
> Y = np.linspace(-1.19, 1.19, 70)
> (Xs, Ys) = np.meshgrid(X, Y)
> Z = np.sqrt((Xs-0.9)**2 + Ys**2) - 0.10
> fig = plt.figure()
> ax = fig.add_subplot(111)
> ax.contour(X, Y, Z)
> fig.show()
> 
> This works, but gives the y axis a different scale than the x axis so
> the ellipses look like circles.
> 
> How can I get the same scale for the x- and y-axis?
> 
> I tried to set ax.set_autoscale_on(False), but that resulted in a
> totally different part of the coordinate system being 

Try:

ax.set_aspect('equal')

Ryan

------------------------------------------------------------------------------
The Palm PDK Hot Apps Program offers developers who use the
Plug-In Development Kit to bring their C/C++ apps to Palm for a share
of $1 Million in cash or HP Products. Visit us here for more details:
http://p.sf.net/sfu/dev2dev-palm
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users

Reply via email to