em.algo | R Documentation |
A pseudo EM algorithm for quantile regression with measurement error. The measurement error here follows a mixture of normals.
em.algo(
formla,
data,
betmatguess,
tau,
m = 1,
piguess = 1,
muguess = 0,
sigguess = 1,
simstep = "MH",
tol = 0.01,
iters = 400,
burnin = 200,
drawsd = 4,
cl = 1,
messages = FALSE
)
formla |
y ~ x |
data |
a data.frame that contains y and x |
betmatguess |
Initial values for the beta parameters. This should be an LxK matrix where L is the number of quantiles and K is the dimension of the covariates |
tau |
An L-vector indicating which quantiles have been estimated |
m |
The number of components of the mixture distribution for the measurement error |
piguess |
Starting value for the probabilities of each mixture distribution (should have length equal to k) |
muguess |
Starting value for the mean of each mixture component (should have length equal to k) |
sigguess |
Starting value for the standard deviation of each mixture component (should have length equal to k) |
simstep |
Whether to use MH in EM algorithm or importance sampling in EM algorithm. "MH" for MH, and "ImpSamp" for importance sampling. Default is MH. |
tol |
This is the convergence criteria. When the change in the Euclidean distance between the new parameters (at each iteration) and the old parameters (from the previous iteration) is smaller than tol, the algorithm concludes. In general, larger values for tol will result in a fewer number of iterations and smaller values will result in more accurate estimates. |
iters |
How many iterations to use in the simulation step (default is 400) |
burnin |
How many iterations to drop in the simulation step (default is 200) |
drawsd |
The starting standard deviation for the measurement error term. |
cl |
The numbe of clusters to use for parallel computation (default is 1 so that computation is not done in parallel) |
messages |
Whether or not to report details of estimation procedure (default is FALSE) |
QRME object
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.