[SciPy-dev] documenting objects in stats.distributions

David Goldsmith d.l.goldsmith at gmail.com
Wed Dec 16 03:34:52 EST 2009


On Tue, Dec 15, 2009 at 11:58 PM, Christopher Burns <cburns at berkeley.edu> wrote:
> We're working on documentation at the SciPy.in sprints and have run

Thanks!

> into a strange documentation problem.  Several of the distributions
> are objects, not classes, so the documentation page gives a warning

Ummm, what do you mean "objects, not classes"?  Instances of classes?

I trust that, though it might not have been the answer you were hoping
for, Ralf's reply answered your question, yes?

DG

> "Unknown section Methods".
>
> See:
> http://docs.scipy.org/scipy/docs/scipy.stats.alpha/
>
> Is there a way to update the docs to remove this warning?
>
> This is the actual code:
>
> class alpha_gen(rv_continuous):
>   def _pdf(self, x, a):
>       return 1.0/arr(x**2)/special.ndtr(a)*norm.pdf(a-1.0/x)
>   def _cdf(self, x, a):
>       return special.ndtr(a-1.0/x) / special.ndtr(a)
>   def _ppf(self, q, a):
>       return 1.0/arr(a-special.ndtri(q*special.ndtr(a)))
>   def _stats(self, a):
>       return [inf]*2 + [nan]*2
> alpha = alpha_gen(a=0.0,name='alpha',shapes='a',extradoc="""
>
> Alpha distribution
>
> alpha.pdf(x,a) = 1/(x**2*Phi(a)*sqrt(2*pi)) * exp(-1/2 * (a-1/x)**2)
> where Phi(alpha) is the normal CDF, x > 0, and a > 0.
> """)
>
> Thanks!
>
> --
> Christopher Burns
> Computational Infrastructure for Research Labs
> 10 Giannini Hall, UC Berkeley
> 510-643-4053
> http://cirl.berkeley.edu/
> _______________________________________________
> SciPy-Dev mailing list
> SciPy-Dev at scipy.org
> http://mail.scipy.org/mailman/listinfo/scipy-dev
>



More information about the SciPy-Dev mailing list