View source: R/lqquantile_rs.R
| lqquantile_rs | R Documentation |
L_q-quantile score
The function lqquantile_rs computes the realised L_q-quantile score at a
specific level p and parameter q, when \textbf{\textit{y}}
materialises and \textbf{\textit{x}} is the prediction.
Realised L_q-quantile score is a realised score corresponding to the
L_q-quantile scoring function lqquantile_sf.
lqquantile_rs(x, y, p, q)
x |
Prediction. It can be a vector of length |
y |
Realisation (true value) of process. It can be a vector of length
|
p |
It can be a scalar. |
q |
It can be a scalar. |
The realised L_q-quantile score is defined by:
S(\textbf{\textit{x}}, \textbf{\textit{y}}, p, q) := (1/n)
\sum_{i = 1}^{n} L(x_i, y_i, p, q)
where
\textbf{\textit{x}} = (x_1, ..., x_n)^\mathsf{T}
\textbf{\textit{y}} = (y_1, ..., y_n)^\mathsf{T}
and
L(x, y, p, q) := |\textbf{1} \lbrace x \geq y \rbrace - p| |x - y|^q
Domain of function:
\textbf{\textit{x}} \in \mathbb{R}^n
\textbf{\textit{y}} \in \mathbb{R}^n
0 < p < 1
q > 1
Range of function:
S(\textbf{\textit{x}}, \textbf{\textit{y}}, p, q) \geq 0,
\forall \textbf{\textit{x}}, \textbf{\textit{y}} \in \mathbb{R}^n,
p \in (0, 1), q > 1
Value of the realised L_q-quantile score.
For details on the L_q-quantile scoring function, see
lqquantile_sf.
The concept of realised (average) scores is defined by Gneiting (2011) and Fissler and Ziegel (2019).
The realised L_q-quantile score is the realised (average) score
corresponding to the L_q-quantile scoring function.
Fissler T, Ziegel JF (2019) Order-sensitivity and equivariance of scoring functions. Electronic Journal of Statistics 13(1):1166–1211. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1214/19-EJS1552")}.
Gneiting T (2011) Making and evaluating point forecasts. Journal of the American Statistical Association 106(494):746–762. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1198/jasa.2011.r10138")}.
lqquantile_sf
# Compute the realised Lq-quantile score.
set.seed(12345)
p <- 0.7
q <- 2
x <- qnorm(p = p, mean = 0, sd = 1)
y <- rnorm(n = 100, mean = 0, sd = 1)
print(lqquantile_rs(x = x, y = y, p = p, q = q))
print(lqquantile_rs(x = rep(x = x, times = 100), y = y, p = p, q = q))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.