You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
buildmer makes it easy to perform stepwise elimination of mixed-effects models fit and it would be nice if this is supported in broom.mixed-
library(buildmer)
m<- buildlme(Reaction~Days+ (Days|Subject), data=lme4::sleepstudy)
#> Determining predictor order#> Fitting via lm: Reaction ~ 1#> Currently evaluating LRT for: Days#> Fitting via lm: Reaction ~ 1 + Days#> Updating formula: Reaction ~ 1 + Days#> Fitting via gls (because REML was requested): Reaction ~ 1 + Days#> Currently evaluating LRT for: 1 | Subject#> Fitting via lme, with REML: Reaction ~ 1 + Days, random=~1 | Subject#> Updating formula: Reaction ~ 1 + Days + (1 | Subject)#> Currently evaluating LRT for: Days | Subject#> Fitting via lme, with REML: Reaction ~ 1 + Days, random=~1 + Days | Subject#> Updating formula: Reaction ~ 1 + Days + (1 + Days | Subject)#> Fitting ML and REML reference models#> Fitting via lme, with REML: Reaction ~ 1 + Days, random=~1 + Days | Subject#> Fitting via lme, with ML: Reaction ~ 1 + Days, random=~1 + Days | Subject#> Testing terms#> Fitting via lme, with REML: Reaction ~ 1 + Days, random=~1 | Subject#> grouping term block score LRT Iteration#> 1 <NA> 1 NA NA 1 NA NA 1#> 2 <NA> Days NA NA Days -32.67300 NA 1#> 3 Subject 1 NA Subject 1 -56.86469 NA 1#> 4 Subject Days NA Subject Days -22.11155 2.495021e-10 1#> All terms are significant
summary(m)
#> Linear mixed-effects model fit by REML#> Data: lme4::sleepstudy #> AIC BIC logLik#> 1755.628 1774.719 -871.8141#> #> Random effects:#> Formula: ~1 + Days | Subject#> Structure: General positive-definite, Log-Cholesky parametrization#> StdDev Corr #> (Intercept) 24.740241 (Intr)#> Days 5.922103 0.066 #> Residual 25.591843 #> #> Fixed effects: Reaction ~ 1 + Days #> Value Std.Error DF t-value p-value#> (Intercept) 251.40510 6.824516 161 36.83853 0#> Days 10.46729 1.545783 161 6.77151 0#> Correlation: #> (Intr)#> Days -0.138#> #> Standardized Within-Group Residuals:#> Min Q1 Med Q3 Max #> -3.95355735 -0.46339976 0.02311783 0.46339621 5.17925089 #> #> Number of Observations: 180#> Number of Groups: 18
buildmer
makes it easy to perform stepwise elimination of mixed-effects models fit and it would be nice if this is supported inbroom.mixed
-Created on 2019-09-29 by the reprex package (v0.3.0)
Session info
The text was updated successfully, but these errors were encountered: