[matplotlib-devel] Histogram bug introduced in r8218

2010-05-03 Thread Tony S Yu
It seems that changes introduced in r8218 drastically changed how `hist` 
handles Python lists.

For example, the histogram given by the following snippet, works as expected:

>>> x = np.random.randn(100)
>>> plt.hist(x)

However, if you pass a 1D list to `hist`, the 1D list is cast to a list of 
length-1 arrays---each treated as a separate histogram. Continuing the above 
code, check the results of the following:

>>> plt.hist(list(x))

I assume that this behavior is unintended, right?

-Tony 
--
___
Matplotlib-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel


Re: [matplotlib-devel] Histogram bug introduced in r8218

2010-05-03 Thread Eric Firing
On 05/03/2010 01:53 PM, Tony S Yu wrote:
> It seems that changes introduced in r8218 drastically changed how `hist` 
> handles Python lists.
>
> For example, the histogram given by the following snippet, works as expected:
>
 x = np.random.randn(100)
 plt.hist(x)
>
> However, if you pass a 1D list to `hist`, the 1D list is cast to a list of 
> length-1 arrays---each treated as a separate histogram. Continuing the above 
> code, check the results of the following:
>
 plt.hist(list(x))
>
> I assume that this behavior is unintended, right?

Fixed in svn 8293.

Eric

>
> -Tony
> --
> ___
> Matplotlib-devel mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/matplotlib-devel


--
___
Matplotlib-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel