lqm is used to fit linear quantile models based on the asymmetric Laplace distribution.lqm(formula, data, subset, na.action, weights = NULL, iota = 0.5,
contrasts = NULL, control = list(), fit = TRUE)formula for fixed effects: a symbolic description of the model to be fitted.as.data.frame to a data frame) containing the variables in the model. If not found in data, the variables are taken from envirna.action setting of options.iota, otherwise the executmodel.matrix.default.lqmControl.FALSE the function returns a list of arguments to be passed to lqm.fit.gs.lqm returns an object of class lqm.
The function summary is used to obtain and print a summary of the results. The generic accessor functions coefficients, predict and residuals extract various useful features of the value returned by lqm.
An object of class lqm is a list containing the following components:theta is a named matrix of coefficients when iota is a vector of values.lqm.fit.gs).weights = NULL).lqmControl).summary.lqmset.seed(12356)
n <- 200
p <- 1:3/4
test <- data.frame(x = runif(n,0,1))
test$y <- 30 + test$x + rnorm(n)
fit.lqm <- lqm(y ~ x, data = test, iota = p,
control = list(verbose = FALSE, loop_tol = 0.001), fit = TRUE)
fit.lqmRun the code above in your browser using DataLab