Skip to content

Instantly share code, notes, and snippets.

@jcheong0428
Last active March 20, 2021 06:02
Show Gist options
  • Select an option

  • Save jcheong0428/802f4adc7535c90b2d8981502df787bd to your computer and use it in GitHub Desktop.

Select an option

Save jcheong0428/802f4adc7535c90b2d8981502df787bd to your computer and use it in GitHub Desktop.
LMER in Pymer4
# Install pymer4
!pip install -q pymer4
# load pymer4
from pymer4.models import Lmer
model = Lmer('Weight ~ Time + Evit + (1 + Time|Pig)', data=data)
display(model.fit())
# ANOVA results from fitted model
display(model.anova())
# Plot estimated model coefficients
model.plot_summary()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment