Turns out this is what I was looking for !
http://matplotlib.sourceforge.net/examples/pylab_examples/subplots_demo.html#pylab-examples-subplots-demo
f, axarr = plt.subplots(2, 2)
axarr[0,0].plot(x, y)
axarr[0,0].set_title('Axis [0,0]')
axarr[0,1].scatter(x, y)
axarr[0,1].set_title('Axis [0,1]')
a
Paul,
That fixes my problem perfectly. Thanks for the solution!
Best,
Brad
On Thu, Mar 29, 2012 at 1:59 PM, Paul Hobson wrote:
> Brad,
>
> Matplotlib axes objects have set_xticklabels methods. It's brute
> force, but this will work:
> ax = gca()
> ax.set_xticks([0., 0.015, 0.03])
> ax.set_xtic
Brad,
Matplotlib axes objects have set_xticklabels methods. It's brute
force, but this will work:
ax = gca()
ax.set_xticks([0., 0.015, 0.03])
ax.set_xticklabels(['0', '0.015', '0.03'])
Hope that helps,
-paul
On Thu, Mar 29, 2012 at 1:13 PM, Brad Malone wrote:
> Hello,
>
> I am working on a plo
Hello,
I am working on a plot in which I need to modify the value of the xticks. A
snippet of my code is attached below:
fig=figure()
>
> gs=matplotlib.gridspec.GridSpec(1,2,width_ratios=[3,1])
> gs.update(wspace=0.1)
> ax=subplot(gs[0])
> ylabel('Frequency (cm'+r'$^
On Thu, Mar 29, 2012 at 1:31 PM, Chao YUE wrote:
> Dear all,
>
> here in cookbook it says "Ever wanted to reverse a colormap, or to
> desaturate one ? Here is a routine to apply a function to the look up table
> of a colormap: "
> http://www.scipy.org/Cookbook/Matplotlib/ColormapTransformations
>
Dear all,
here in cookbook it says "Ever wanted to reverse a colormap, or to
desaturate one ? Here is a routine to apply a function to the look up table
of a colormap: "
http://www.scipy.org/Cookbook/Matplotlib/ColormapTransformations
but I don't know how to use cmap_map function as in the link t
Hello,
I am programming using POO (object programming)
I cannot find a way to create a plot as an object
In concept, I would like to do something like
"""
from matplotlib.backends.backend_qt4agg import FigureCanvasQTAgg as FigureCanvas
from matplotlib.figure import Figure
self.figure = Figure
I never got the trick with set_yscale="clip" to work for my plots (MPL
1.1.0).
So I'm passing my error values to this little function in order to correct
the yerr_neg:
def filt_neg_err(y, yerr, set_ymin=1e-6):
ymin = y - yerr
filt = ymin < 0
yerr_pos = yerr.copy()
yerr_neg = yerr.
Dear all,
I make a contourf plot but I think the colorbar is too wide. Can I make it
narrower (slimmer)?
plt.contourf(data)
cbar=plt.colorbar()
??
thanks for any suggestions.
cheers,
Chao
--
***
Chao YUE
Laborat
On Tue, Mar 27, 2012 at 3:31 AM, Mike Kaufman wrote:
> On 3/26/12 12:49 PM, Christopher Graves wrote:
>
>> On Sun, Mar 11, 2012 at 2:32 PM, Christopher Graves
>> mailto:christoph.gra...@gmail.com>> wrote:
>>
>
> Try this:
>>
>>from pylab import *
>>from matplotlib.ticker i
10 matches
Mail list logo