Description Usage Arguments Value References Examples
Expectiles, introduced by Newey and Powell (1987), are analogs of the quantiles which minimize an asymmetric quadratic objective function rather than the asymmetric linear objective function which defines the quantiles.
1 |
x |
a vector |
probs |
the expectiles desired |
hd |
if TRUE (the default) the Harrell-Davis method is used to refine the expectiles by passing the expectile
estimates to the empirical cumulative density function for the data to obtain the equivalent
quantile probabilities, then utilizing the |
a named numeric vector
Newey, W., & Powell, J. (1987). Asymmetric Least Squares Estimation and Testing.
1 2 3 4 5 6 7 | ## To understand how the Harrell-Davis method is used to refine the expectiles, first get the raw expectiles.
ex<-expectile(iris$Sepal.Length,hd=F)
## Plug these estimates into the ecdf to obtain the quantile probabilites.
q<-ecdf(iris$Sepal.Length)(ex)
## Pass the quantiles to the hdquantile function. These quantiles correspond to the expectiles.
hdquantile(iris$Sepal.Legth)
## However,you can just use expectile(iris$Sepal.Length), as the hd adjustment is enabled by default.
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.