[SciPy-User] scipy.stats.invnorm - rename to invgauss?
josef.pktd@gmai...
josef.pktd@gmai...
Wed Apr 7 14:11:02 CDT 2010
On Wed, Apr 7, 2010 at 3:05 PM, <josef.pktd@gmail.com> wrote:
> On Wed, Apr 7, 2010 at 2:45 PM, Matthew Brett <matthew.brett@gmail.com> wrote:
>> Hi,
>>
>> I was caught in the same trap as another innocent, in thinking that
>> scipy.stats.invnorm was the inverse of the normal distribution:
>>
>> http://bytes.com/topic/python/answers/478142-scipy-numpy-inverse-cumulative-normal
>>
>> In my desire to improve the docstring, I started looking; after a
>> while I found this:
>>
>> http://en.wikipedia.org/wiki/Inverse_Gaussian_distribution
>>
>> - and that seems to fit the invnorm code.
>>
>> A Google search for 'inverse normal distribution' does not include the
>> page above in the first 20 hits, but does find the inverse of the
>> normal distribution, and this:
>>
>> http://en.wikipedia.org/wiki/Normal-inverse_Gaussian_distribution
>>
>> I wonder whether it would be good to rename scipy.stats.invnorm to
>> scipy.stats.invgauss ? Maybe with a deprecation warning to invnorm?
>
> in general I wouldn't mind, but for naming consistency I prefer the current name
>
> distributions created by some transformation of the normal distribution:
>
>>>> [i for i in dir(stats) if 'norm' in i and isinstance(getattr(stats,i), stats.distributions.rv_generic)]
> ['foldnorm', 'halfnorm', 'invnorm', 'lognorm', 'norm', 'powerlognorm',
> 'powernorm', 'truncnorm']
>
> I don't think the confusion persists very long, invnorm is a
> distribution, the inverse function of the cdf of the normal
> distribution is a function or in our case a method (ppf).
But from http://en.wikipedia.org/wiki/Inverse_Gaussian_distribution
it looks like it's not a inverse transformation. In that case a
different name might reduce some confusion.
I will look at what invnorm really is, (I don't know)
Josef
>
> Josef
>
>
>>
>> Best,
>>
>> Matthew
>> _______________________________________________
>> SciPy-User mailing list
>> SciPy-User@scipy.org
>> http://mail.scipy.org/mailman/listinfo/scipy-user
>>
>
More information about the SciPy-User
mailing list