Mixed profile #2111

Merged
merged 2 commits into from Dec 2, 2014

Projects

None yet

3 participants

@kshedden
Contributor

This should close #2102. I did not correctly update the profile likelihood code after creating a class for managing the model parameters.

I also updated the notebook at:

http://nbviewer.ipython.org/urls/umich.box.com/shared/static/6tfc1e0q6jincsv5pgfa.ipynb

@coveralls

Coverage Status

Coverage decreased (-0.0%) when pulling ac39438 on kshedden:mixed_profile into b3f5ad0 on statsmodels:master.

@jseabold jseabold added this to the 0.6.1 milestone Dec 2, 2014
@jseabold
Member
jseabold commented Dec 2, 2014

Thanks. FYI, this notebook is now in our examples/ using R magic.

@jseabold jseabold merged commit 2a80413 into statsmodels:master Dec 2, 2014

1 check passed

continuous-integration/travis-ci The Travis CI build passed
Details
@jseabold
Member
jseabold commented Dec 2, 2014

FYI, this still doesn't work for me, though the error message is a little nicer.


---------------------------------------------------------------------------
ValueError                                Traceback (most recent call last)
<ipython-input-28-3cb42083aeba> in <module>()
      1 re = mdf.cov_re.iloc[1, 1]
----> 2 likev = mdf.profile_re(1, dist_low=0.8*re, dist_high=0.8*re)
      3 
      4 plt.figure(figsize=(10, 8))
      5 plt.plot(likev[:,0], 2*likev[:,1])

/home/skipper/statsmodels/statsmodels/statsmodels/regression/mixed_linear_model.pyc in profile_re(self, re_ix, num_low, dist_low, num_high, dist_high)
   2103                     np.fill_diagonal(cov_re, dg)
   2104             if not success:
-> 2105                 raise ValueError("unable to find PSD covariance matrix along likelihood profile")
   2106 
   2107             params.set_cov_re(cov_re)

ValueError: unable to find PSD covariance matrix along likelihood profile
@jseabold
Member
jseabold commented Dec 2, 2014

Decreasing the size of the interval works though.

@jseabold jseabold added a commit that referenced this pull request Dec 2, 2014
@jseabold jseabold Backport PR #2111: Mixed profile
This should close #2102.  I did not correctly update the profile likelihood code after creating a class for managing the model parameters.

I also updated the notebook at:

http://nbviewer.ipython.org/urls/umich.box.com/shared/static/6tfc1e0q6jincsv5pgfa.ipynb
13eaf0c
@kshedden kshedden deleted the kshedden:mixed_profile branch Jul 1, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment