Learn R Programming

ALDqr (version 1.0)

EM.qr: Quantile Regression Using Asymmetric Laplace Distribution

Description

Return estimating the parameters in a quantile regression

Usage

EM.qr(y, x = NULL, tau = NULL, error = 0.000001 , iter = 2000, envelope=FALSE)

Arguments

y
vector of responses
x
the design matrix
tau
the quantile to be estimated, this is generally a number strictly between 0 and 1.
error
the covergence maximum error
iter
maximum iterations of the EM algorithm.
envelope
confidence envelopes for a curve based on bootstrap replicates

Value

References

[1] Koenker, R. W. (2005). Quantile Regression, Cambridge U. Press.

[2] Yu, K. & Moyeed, R. (2001). Bayesian quantile regression. Statistics & Probability Letters, 54 (4), 437 to 447.

[3] Kotz, S., Kozubowski, T. & Podgorski, K. (2001). The laplace distribution and generalizations: A revisit with applications to communications, economics, engineering, and finance. Number 183. Birkhauser.

Examples

Run this code
data(ais, package="sn")
attach(ais)
sexInd <- (sex=="female") + 0
x      <- cbind(1,LBM,sexInd)
y      <- BMI
tau    <- 0.5

## EM.qr
EM.qr(y,x,tau)


Run the code above in your browser using DataLab