Learn R Programming

lqmm (version 1.02)

lqmm.fit.df: Linear Quantile Mixed Models Fitting by Derivative-Free Optimization

Description

This function controls the arguments to be passed to optim and optimize for LQMM estimation.

Usage

lqmm.fit.df(theta_0, x, y, z, weights, cov_name, V, W, sigma_0,	
	iota, group, control)

Arguments

theta_0
starting values for the linear predictor.
x
the model matrix for fixed effects.
y
the model response.
z
the model matrix for random effects.
weights
the weights used in the fitting process.
cov_name
variance--covariance matrix of the random effects. Default is pdIdent. See details.
V
nodes of the quadrature.
W
weights of the quadrature.
sigma_0
starting value for the scale parameter.
iota
the quantile(s) to be estimated.
group
the grouping factor.
control
list of control parameters used for optimization (see lqmmControl).

Value

  • An object of class "list" containing the following components:
  • thetaa vector of coefficients, including the "raw" variance--covariance parameters (see cov.lqmm).
  • scalethe scale parameter.
  • logLikthe log--likelihood.
  • optnumber of iterations when the estimation algorithm stopped for lower (theta) and upper (scale) loop.
  • .

Details

In lqmm, see argument fit for generating a list of arguments to be called by this function; see argument covariance for alternative variance--covariance matrices.

See Also

lqmm

Examples

Run this code
set.seed(123)

M <- 50
n <- 10
test <- data.frame(x = runif(n*M,0,1), group = rep(1:M,each=n))
test$y <- 10*test$x + rep(rnorm(M, 0, 2), each = n) + rchisq(n*M, 3)
lqmm.ls <- lqmm(fixed = y ~ x, random = ~ 1, group = group, data = test,
	fit = FALSE)

do.call("lqmm.fit.df", lqmm.ls)

Run the code above in your browser using DataLab