The model for linear quantile regression is

where is the vector of responses, is the regressor matrix, is the vector of unknown parameters, and is the vector of unknown errors.
regression, also known as median regression, is a natural extension of the sample median when the response is conditioned on the covariates. In regression, the least absolute residuals estimate , referred to as the norm estimate, is obtained as the solution of the minimization problem

More generally, for quantile regression Koenker and Bassett (1978) defined the regression quantile, , as any solution to the minimization problem

The solution is denoted as , and the norm estimate corresponds to . The regression quantile is an extension of the sample quantile , which can be formulated as the solution of

If you specify weights , with the WEIGHT statement, weighted quantile regression is carried out by solving

Weighted regression quantiles can be used for Lestimation; see Koenker and Zhao (1994).