Hi,
Thanks for the reply.
I did already try it and still go the same trace back. I tried with long
arrays [1,2,....,n] and with short ones. I also tried with single numbers. 
How can it get an out of range array?

  File "gcview.py", line 87, in drawGraph
    plot([0],[0])
  File "/usr/local/lib/python2.6/site-packages/matplotlib/pyplot.py", line
2287, in plot
    ret = ax.plot(*args, **kwargs)
  File "/usr/local/lib/python2.6/site-packages/matplotlib/axes.py", line
3776, in plot
    self.autoscale_view(scalex=scalex, scaley=scaley)
  File "/usr/local/lib/python2.6/site-packages/matplotlib/axes.py", line
1793, in autoscale_view
    x0, x1 = xlocator.view_limits(x0, x1)
  File "/usr/local/lib/python2.6/site-packages/matplotlib/ticker.py", line
1176, in view_limits
    return np.take(self.bin_boundaries(dmin, dmax), [0,-1])
  File "/usr/local/lib/python2.6/site-packages/numpy/core/fromnumeric.py",
line 103, in take
    return take(indices, axis, out, mode)
IndexError: index out of range for array




John Hunter-4 wrote:
> 
> On Wed, Jul 21, 2010 at 10:05 AM, alberttresens
> <albert.tres...@gmail.com> wrote:
>>
>> I am getting this trace when trying to plot. I tried all possible
>> combinations in the plot parameters, always the same. Can someone recon
>> what
>> is happening?
>>
>> Traceback (most recent call last):
>>  File "gcview.py", line 226, in <module>
>>    main()
>>  File "gcview.py", line 222, in main
>>    drawGraph(timeStatpsBeforeGc, usedBeforeGc, timeStampsAfterGc,
>> usedAfterGc, heapSizes, timeStampsForFullGc, fullGcIndicators,
>> logStartTS,
>> logEndTS, output)
>>  File "gcview.py", line 87, in drawGraph
>>    plot(0,0)
> 
> Recent versions of mpl support plotting of scalars, but older versions
> require plotting sequences.  Here you might try:
> 
>   plot([0], [0])
> 
> instead of
> 
>   plot(0, 0)
> 
> JDH
> 
> ------------------------------------------------------------------------------
> This SF.net email is sponsored by Sprint
> What will you do first with EVO, the first 4G phone?
> Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first
> _______________________________________________
> Matplotlib-users mailing list
> Matplotlib-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
> 
> 

-- 
View this message in context: 
http://old.nabble.com/Plot%28%29-%3A-IndexError%3A-index-out-of-range-for-array-tp29226333p29234467.html
Sent from the matplotlib - users mailing list archive at Nabble.com.


------------------------------------------------------------------------------
This SF.net email is sponsored by Sprint
What will you do first with EVO, the first 4G phone?
Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users

Reply via email to