Hi, I have problems with plotting in matplotlib. I want to plot something and then overlay this plot with a scatter plot, so like this: clf() plot( sx, sy, 'kx') hold(True) scatter( ix, iy, 40, c=iz, faceted=False) colorbar() hold(False) Although the scatter command is called later, any point drawn with the " scatter"-command lies behind the black crosses drawn by the "plot" command. Any ideas how to get the order right? Cheers Alex
"Alexander Dietz" <Ale...@as...> writes: > Although the scatter command is called later, any point drawn with the " > scatter"-command lies behind the black crosses drawn by the "plot" command. > Any ideas how to get the order right? Set the zorder property. Try e.g.: clf() l=plot(rand(50), rand(50), 'kx') p=scatter(rand(20), rand(20), 40, c=rand(20), faceted=False) getp(l[0], 'zorder') getp(p, 'zorder') setp(p, zorder=3) -- Jouni K. Seppänen http://www.iki.fi/jks