[Numpy-discussion] Getting 95%/99% margin of ndarray

Pierre GM pgmdevlist at gmail.com
Thu Jul 23 06:16:27 EDT 2009


On Jul 23, 2009, at 6:07 AM, Scott Sinclair wrote:

>> 2009/7/22 Pierre GM <pgmdevlist at gmail.com>:
>> You could try scipy.stats.scoreatpercentile,
>> scipy.stats.mstats.plottingposition or scipy.stats.mstats.mquantiles,
>> which will all approximate quantiles of your distribution.
>
> It seems that mquantiles doesn't do what you'd expect when the limit
> keyword argument is specified. There's a patch for review here:

Thx for the patch, I'll port it in the next few hours. However, I  
disagree with the last few lines (where the quantiles are transformed  
to a standard ndarray if the mask is nomask. For consistency, we  
should always have a MaskedArray, don't you think ? (And anyway,  
taking a view as a ndarray is faster than using np.asarray...)
Thx again
P.



More information about the NumPy-Discussion mailing list