# How do the random effects relate to the fixed effects in the output from a mixed model?

When I run my output from the lmer function for random effects, I get something like this:

form_lmer1 <- "y  ~   1 + Var1 + (1+Var1 | group)"
fm3        <- lmer(as.formula(form_lmer1), df, REML=FALSE, verbose=TRUE)
ranef(fm3)
# \$group
#      (Intercept)                    Var1
# 500  0.044211088           -0.0127878291
# 501 -0.047100911            0.0779782538
# 502  0.038150455           -0.0073571972
# 504  0.040368393           -0.0089280108
# 505  0.062128815           -0.0308154532
# 506  0.004291613            0.0265210988


Are these just the differences of the fixed effects / coefficients?

fixef(fm3)
#  (Intercept)                    Var1
#  0.970103582             0.001630575


So if I wanted to calculate the new coefficients by group, I would just add/subtract from the fixed effect?

In the outputted lmer object, you should be able to use coef(object), and get the summed fixed and random effects, or you can get the individually (as you do here), and sum them yourself.