1\name{LassoLambdaHat}
2\alias{LassoLambdaHat}
3\title{Lambda selection for QR lasso problems}
4\description{
5    Default procedure for selection of lambda in lasso constrained
6    quantile regression as proposed by Belloni and Chernozhukov (2011)
7}
8\usage{
9LassoLambdaHat(X, R = 1000, tau = 0.5, C = 1, alpha = 0.95)
10}
11\arguments{
12  \item{X}{Design matrix}
13  \item{R}{Number of replications}
14  \item{tau}{quantile of interest}
15  \item{C}{Cosmological constant}
16  \item{alpha}{Interval threshold}
17}
18\value{
19    vector of default lambda values of length p, the column dimension of X.
20}
21\details{
22  As proposed by Belloni and Chernozhukov, a reasonable default lambda
23  would be the upper quantile of the simulated values.  The procedure is based
24  on idea that a simulated gradient can be used as a pivotal statistic.
25  Elements of the default vector are standardized by the respective standard deviations
26  of the covariates. Note that the sqrt(tau(1-tau)) factor cancels in their (2.4) (2.6).
27  In this formulation even the intercept is penalized.  If the lower limit of the
28  simulated interval is desired one can specify \code{alpha = 0.05}.
29
30}
31\references{
32    Belloni, A. and  V. Chernozhukov. (2011) l1-penalized quantile regression
33    in high-dimensional sparse models. \emph{Annals of Statistics}, 39 82 - 130.
34}
35\examples{
36n <- 200
37p <- 10
38x <- matrix(rnorm(n*p), n, p)
39b <- c(1,1, rep(0, p-2))
40y <- x \%*\% b + rnorm(n)
41f <- rq(y ~ x, tau = 0.8, method = "lasso")
42# See f$lambda to see the default lambda selection
43}
44