I am using the lme4
R package to create a linear mixed model using the lmer()
function. In this model I have four random effects and one fixed effect (intercept). My question is about the estimated variances of the random effects. Is it possible to specify initial values for the covariance parameters in a similar way as it can be done in SAS
with the PARMS
argument.
In the following example, the estimated variances are:
c(0.00000, 0.03716, 0.00000, 0.02306)
I would like to fix these to (for example)
c(0.09902947, 0.02460464, 0.05848691, 0.06093686)
so there are not estimated.
> summary(mod1)
Linear mixed model fit by maximum likelihood ['lmerMod']
Formula: log_cumcover_mod ~ (1 | kildestationsnavn) + (1 | year) + (1 |
kildestationsnavn:year) + (1 | proevetager)
Data: res
AIC BIC logLik deviance df.resid
109.9 122.9 -48.9 97.9 59
Scaled residuals:
Min 1Q Median 3Q Max
-2.1056 -0.6831 0.2094 0.8204 1.7574
Random effects:
Groups Name Variance Std.Dev.
kildestationsnavn:year (Intercept) 0.00000 0.0000
kildestationsnavn (Intercept) 0.03716 0.1928
proevetager (Intercept) 0.00000 0.0000
year (Intercept) 0.02306 0.1518
Residual 0.23975 0.4896
Number of obs: 65, groups:
kildestationsnavn:year, 6; kildestationsnavn, 3; proevetager, 2; year, 2
Fixed effects:
Estimate Std. Error t value
(Intercept) 4.9379 0.1672 29.54
See Question&Answers more detail:os