Could you please tell me how to get/compute the value RMSE (root mean square error) in R when you perform a mixed effect model
Data: na.omit(binh)
AIC BIC logLik
888.6144 915.1201 -436.3072
Random effects:
Formula: ~1 | Study
(Intercept) Residual
StdDev: 3.304345 1.361858
Fixed effects: Eeff ~ ADF + CP + DE + ADF2 + DE2
Value Std.Error DF t-value p-value
(Intercept) -0.66390 18.870908 158 -0.035181 0.9720
ADF 1.16693 0.424561 158 2.748556 0.0067
CP 0.25723 0.097524 158 2.637575 0.0092
DE -36.09593 12.031791 158 -3.000046 0.0031
ADF2 -0.03708 0.011014 158 -3.366625 0.0010
DE2 4.77918 1.932924 158 2.472513 0.0145
Correlation:
(Intr) ADF CP DE ADF2
ADF -0.107
CP -0.032 0.070
DE 0.978 -0.291 -0.043
ADF2 0.058 -0.982 -0.045 0.250
DE2 -0.978 0.308 0.039 -0.997 -0.265
Standardized Within-Group Residuals:
Min Q1 Med Q3 Max
-2.28168116 -0.45260885 0.06528363 0.57071734 2.54144168
Number of Observations: 209
Number of Groups: 46
The same result can be obtained from:
library(nlme)
library(sjstats)
fit <- lmer(Yield ~ Species + (1|Population/variety), data = df1,REML=T)
rmse(fit)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With