From: <fcc...@fi...> - 2005-01-17 12:56:04
|
On Friday 14 January 2005 14:48, Dominique Orban wrote: I don't get any zig-zag lines on my box when I run your code... as for being sideways, I cant tell since I don't have matlab here... I don't have a solution, but it doesn't seem to be a matplotlib problem. I am running, version 0.70.1 good luck, =46l=E1vio > Hi, > > When trying to plot the contours of the famous Rosenbrock function: > > ---------------------------------------- > from matplotlib.pylab import * > > def rosenbrock(x,y): > return 10.0 * (y-x**2)**2 + (x-1)**2 > > x =3D arange( -1.5, 1.5, 0.01 ) > y =3D arange( -0.5, 1.5, 0.01 ) > [X,Y] =3D meshgrid( x, y ) > Z =3D rosenbrock( X, Y ) > contour( Z, x=3DX, y=3DY, levels =3D 50 ) > show() > ---------------------------------------- > > I notice some spurious zigzagging lines towards the top of the plot. Any > idea where those might be coming from? > > Also, the figure produced by the above script is flipped horizontally. > The corresponding Matlab script produces the correct plot. > > Thanks, > Dominique > > > ------------------------------------------------------- > The SF.Net email is sponsored by: Beat the post-holiday blues > Get a FREE limited edition SourceForge.net t-shirt from ThinkGeek. > It's fun and FREE -- well, almost....http://www.thinkgeek.com/sfshirt > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users |