Re: [Matplotlib-users] his problems...

2010-02-10 Thread Matthias Michler
On Tuesday 09 February 2010 17:38:18 Nick Schurch wrote:
 HI all,

 I've been using matplotlip for a while now but mainly for line plots,
 scatter plots and the odd dendrogram. I recently tried plotting a
 histogram (of a binomial function) and encountered a problem. So I
 though I'd try the extremely simple example set on the front of the
 matplotlib page and heres what I got:

 Python 2.4.3 (#1, Sep  3 2009, 15:37:12)
 [GCC 4.1.2 20080704 (Red Hat 4.1.2-46)] on linux2
 Type help, copyright, credits or license for more information.

  from pylab import randn, hist
  x = randn(1)
  hist(x, 100)

 Traceback (most recent call last):
   File stdin, line 1, in ?
   File /usr/lib/python2.4/site-packages/matplotlib/pyplot.py, line
 1633, in hist
 ret =  gca().hist(*args, **kwargs)
   File /usr/lib/python2.4/site-packages/matplotlib/axes.py, line 5060, in
 hist align=align, log=log)
   File /usr/lib/python2.4/site-packages/matplotlib/axes.py, line 3253, in
 bar assert len(height)==nbars, argument 'height' must be %d or scalar %
 nbars AssertionError: argument 'height' must be 101 or scalar

 Any idea why this isn't working? I have matplotlib v0.91.2 - will
 updating to 0.99 solve the problem?

Hi, 

I'm using 

Python 2.5.2 (r252:60911, Jan 20 2010, 21:48:48) 
[GCC 4.2.4 (Ubuntu 4.2.4-1ubuntu3)] on linux2
Type help, copyright, credits or license for more information.
 from pylab import randn, hist, show
 x = randn(1)
 hist(x, 100)
 show()
 import matplotlib
 matplotlib.__version__
'0.91.2'

and get a nice figure with a 100-bins histogram. I don't know what's going 
wrong with your installation.

Kind regards,
Matthias

--
SOLARIS 10 is the OS for Data Centers - provides features such as DTrace,
Predictive Self Healing and Award Winning ZFS. Get Solaris 10 NOW
http://p.sf.net/sfu/solaris-dev2dev
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


[Matplotlib-users] his problems...

2010-02-09 Thread Nick Schurch
HI all,

I've been using matplotlip for a while now but mainly for line plots,
scatter plots and the odd dendrogram. I recently tried plotting a
histogram (of a binomial function) and encountered a problem. So I
though I'd try the extremely simple example set on the front of the
matplotlib page and heres what I got:

Python 2.4.3 (#1, Sep  3 2009, 15:37:12)
[GCC 4.1.2 20080704 (Red Hat 4.1.2-46)] on linux2
Type help, copyright, credits or license for more information.
 from pylab import randn, hist
 x = randn(1)
 hist(x, 100)
Traceback (most recent call last):
  File stdin, line 1, in ?
  File /usr/lib/python2.4/site-packages/matplotlib/pyplot.py, line
1633, in hist
ret =  gca().hist(*args, **kwargs)
  File /usr/lib/python2.4/site-packages/matplotlib/axes.py, line 5060, in hist
align=align, log=log)
  File /usr/lib/python2.4/site-packages/matplotlib/axes.py, line 3253, in bar
assert len(height)==nbars, argument 'height' must be %d or scalar % nbars
AssertionError: argument 'height' must be 101 or scalar

Any idea why this isn't working? I have matplotlib v0.91.2 - will
updating to 0.99 solve the problem?
-- 
Cheers,

Nick Schurch

--
The Planet: dedicated and managed hosting, cloud storage, colocation
Stay online with enterprise data centers and the best network in the business
Choose flexible plans and management services without long-term contracts
Personal 24x7 support from experience hosting pros just a phone call away.
http://p.sf.net/sfu/theplanet-com
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users