Skip to content

Commit

Permalink
initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
kshedden committed Nov 22, 2020
1 parent 874c666 commit 2fc175a
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions statsmodels/regression/mixed_linear_model.py
Expand Up @@ -2260,6 +2260,16 @@ def fit(self, start_params=None, reml=True, niter_sa=0,
"is not positive definite.")
warnings.warn(msg, ConvergenceWarning)

if hasattr(self.exog, "names"):
fe_params = pd.Series(fe_params, self.exog.names)

if hasattr(self.exog_re, "names"):
na = self.exog_re.names
cov_re = pd.DataFrame(fe_params, columns=na, index=na)

if hasattr(self.exog_vc, "names"):
vcomp = pd.Series(vcomp, self.exog_vc.names)

# Prepare a results class instance
params_packed = params.get_packed(use_sqrt=False, has_fe=True)
results = MixedLMResults(self, params_packed, pcov / scale)
Expand Down

0 comments on commit 2fc175a

Please sign in to comment.