Re: Trying to understand Distributions

Robert Kern <[email protected]> Tue, 13 Jul 2021 00:23:17 -0400
Newsgroups gmane.comp.python.scientific.user
Message-ID <CAF6FJivGhw8a-pG54wrkksyACtUEsA+iG-UfwDLmfHw-OHOYoA@mail.gmail.com>
Please try to respond to these messages so that the email thread remains
intact. You are making a new thread with each email, which makes the
discussion difficult to follow. It would help me refer back to what we've
gone over previously.

On Tue, Jul 13, 2021 at 12:16 AM Keith Sloan <[email protected]> wrote:

> Again another unsuccessful attempt trying to follow Roberts advice
>
> Data is astronomic so loc = 0 is not okay
>
Okay, then don't omit it.

> ax4 = fig.add_subplot(4, 1, 4)
>
> ag2, bg2, cg2 =stats.gamma.fit(RErange1[xfield].data)
> print(ag2, bg2, cg2)
> x0, x1 = stats.gamma.ppf([0.1, 0.99], ag2, scale=cg2)
> x = np.linspace(stats.gamma.ppf(x0,x1, int(ag2)))
> ax4.plot(x, stats.gamma.pdf(x, ag2, scale = cg2),'r-', lw=5, alpha=0.6,
> label='gamma pdf')
>
x0, x1 = stats.gamma.ppf([0.1, 0.99], ag2, loc=bg2, scale=cg2)
x = np.linspace(stats.gamma.ppf(x0,x1, int(ag2)))
ax4.plot(x, stats.gamma.pdf(x, ag2, loc=bg2, scale = cg2),'r-', lw=5,
alpha=0.6, label='gamma pdf')

-- 
Robert Kern

_______________________________________________
SciPy-User mailing list
[email protected]
https://mail.python.org/mailman/listinfo/scipy-user