I'm trying to generate a contour plot with logarithmic axes. I'm
generating data on a grid defined by logspaces:
x_range = logspace(log10(xstart),log10(xend),num=25)
y_range = logspace(log10(ystart),log10(yend),num=25)
Then, to generate the plot I do the following:
And to obtain nicer tick mark labels, this dirty way:
xmajorForm = pylab.FormatStrFormatter('10e%.1f')
ymajorForm = pylab.FormatStrFormatter('10e%.1f')
Are there better ways to (1) set the x and y xis scaling to
logarithmic, and to (2) obtain nicely formatted tick mark labels ?
I tried playing around with the x and y axis data and with LogLocator
and LogFormatter but it doesn't seem to do the job.