Indeed! Will fix both as soon as I can --- it's a bit awkward to do from
the phone :-)

/Zh
On Jan 24, 2014 4:36 PM, "Josef Perktold" <notifications@github.com> wrote:

> In statsmodels/distributions/tests/test_edgeworth.py:
>
> > +        assert_allclose(ne2.pdf(x), stats.norm.pdf(x, loc=3, scale=2))
> > +
> > +    def test_chi2_moments(self):
> > +        # construct the expansion for \chi^2
> > +        N, df = 6, 15
> > +        cum = [_chi2_cumulant(n+1, df) for n in range(N)]
> > +        ne = ExpandedNormal(cum, name='edgw_chi2')
> > +
> > +        # compare the moments
> > +        assert_allclose([_chi2_moment(n, df) for n in range(N)],
> > +                        [ne.moment(n) for n in range(N)])
> > +
> > +        # compate the pdf
> > +        m, s = df, np.sqrt(2*df)
> > +        x = np.linspace(m - s, m + s, 10)
> > +        assert_allclose(ne.pdf(x), stats.chi2.pdf(x, df=df),
>
> shape parameter df has to be positional in older scipy
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/statsmodels/statsmodels/pull/1325/files#r9154059>
> .
>