Learn R Programming

gamlss (version 4.2-4)

rc: Specify Random Coefficients In A GAMLSS Formula

Description

Fits Random Coefficients In A GAMLSS Model.

Usage

rc(formula, lambda = NULL)

Arguments

formula
a model formula to specify the explanatory variable and the subject grouping factor e.g. formula=~x1|Subjects will fit random constant and slopes for x1 for each level of Subjects
lambda
a matrix specifying the variance-covariance matrix for the random coefficients e.g. lambda=diag{2,5}

Value

  • The variables in the left side of the formula are returned with class "smooth", and attribute named "call" which is to be evaluated in the backfitting additive.fit() called by gamlss()

Warning

This is experimental

Details

This is an experimental function and it is likely to change in the near future. For a chosen fixed variance-covariance matrix for the random coefficients, this function finds the MAP estimates for the constant and slope random effects for the different subjects

References

Rigby, R. A. and Stasinopoulos D. M. (2005). Generalized additive models for location, scale and shape,(with discussion), Appl. Statist., 54, part 3, pp 507-554. Stasinopoulos D. M., Rigby R.A. and Akantziliotou C. (2006) Instructions on how to use the GAMLSS package in R. Accompanying documentation in the current GAMLSS help files, (see also http://www.gamlss.org/) Stasinopoulos D. M. Rigby R.A. (2007) Generalized additive models for location scale and shape (GAMLSS) in R. Journal of Statistical Software, Vol. 23, Issue 7, Dec 2007, http://www.jstatsoft.org/v23/i07. .

See Also

random, ra, gamlss