  The issue of variance components testing arises naturally when building
mixed-effects models, to decide which effects should be modeled as fixed or
random. While tests for fixed effects are available in R for models fitted with
lme4, tools are missing when it comes to random effects. The varTestnlme
package for R aims at filling this gap. It allows to test whether any subset of
the variances and covariances corresponding to any subset of the random
effects, are equal to zero using asymptotic property of the likelihood ratio
test statistic. It also offers the possibility to test simultaneously for fixed
effects and variance components. It can be used for linear, generalized linear
or nonlinear mixed-effects models fitted via lme4, nlme or saemix. Theoretical
properties of the used likelihood ratio test are recalled, numerical methods
used to implement the test procedure are detailed and examples based on
different real datasets using different mixed models are provided.
