This function estimates fixed effects and predicts random effects in two- and three-level random effects nested models using three rank-based fittings (GR, GEER, JR) via the prediction method algorithm RPP.
rlme(f, data, method = "gr", print = FALSE, na.omit = TRUE,
weight = "wil", rprpair = "hl-disp", verbose = FALSE)
An object of class formula describing the mixed effects model. The syntax is same as in the lme4 package. Example: y ~ 1 + sex + age + (1 | region) + (1 | region:school) - sex and age are the fixed effects, region and school are the nested random effects, school is nested within region.
The dataframe to analyze. Data should be cleaned prior to analysis: cluster and subcluster columns are expected to be integers and in order (e.g. all clusters and subclusters )
string indicating the method to use (one of "gr", "jr", "reml", and "geer"). defaults to "gr".
Whether or not to print a summary of results. Defaults to false.
Whether or not to omit rows containing NA values. Defaults to true.
When weight="hbr", it uses hbr weights in GEE weights. By default, ="wil", it uses Wilcoxon weights. See the theory in the references.
By default, it uses "hl-disp" in the random prediction procedure (RPP). Also, "med-mad" would be an alternative.
Boolean indicating whether to print out diagnostic messages.
The function returns a list of class "rlme". Use summary.rlme to see a summary of the fit.
The model formula.
The method used.
Estimate of fixed effects.
Estimate of random effects.
Residuals.
Intra/inter-class correlationa estimates obtained from RPP.
t-values.
p-values.
Location.
Scale.
The response variable y.
Number of observations in provided dataset.
The number of clusters.
The number of subclusters.
Effect from error.
Effect from cluster.
Effect from subcluster.
Variances of fixed effects estimate (Beta estimates).
Weighted design matrix with error covariance matrix.
Weighted response vector with its covariance matrix.
The raw residual.
The raw residual after weighted step. Scaled residual.
The iterative methods GR and GEER can be quite slow for large datasets; try JR for faster analysis. If you want to use the GR method, try using rprpair='med-mad'. This method avoids building a NxN covariance matrix which can quickly become unwieldly with large data.
Y. K. Bilgic. Rank-based estimation and prediction for mixed effects models in nested designs. 2012. URL http://scholarworks.wmich.edu/dissertations/40. Dissertation.
T. P. Hettmansperger and J. W. McKean. Robust Nonparametric Statistical Methods. Chapman Hall, 2012.
summary.rlme, plot.rlme, compare.fits
# NOT RUN {
data(schools)
rlme.fit = rlme(y ~ 1 + sex + age + (1 | region) + (1 | region:school), schools, method="gr")
summary(rlme.fit)
# Try method="geer", "reml", "ml" and "jr" along with
# rprpair="hl-disp" (not robust), and "med-mad" (robust),
# weight="hbr" is for the gee method.
# }
Run the code above in your browser using DataLab