% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/scores.R
\name{qlike_score}
\alias{qlike_score}
\title{Negated QLIKE score for variance forecasts}
\usage{
qlike_score(sigma2_hat, sigma2)
}
\arguments{
\item{sigma2_hat}{Numeric vector. Forecast variance (strictly positive).}

\item{sigma2}{Numeric vector. Realised variance (strictly positive).}
}
\value{
Numeric vector of negated QLIKE scores. Higher is better.
Maximum value is 0, achieved at a perfect forecast \code{sigma2_hat = sigma2}.
Unbounded below.
}
\description{
Computes the positively oriented (negated) QLIKE quasi-likelihood loss for
variance forecasts.
}
\details{
Standard QLIKE loss is
\deqn{L_{QL}(\hat\sigma^2, \sigma^2) = \frac{\sigma^2}{\hat\sigma^2} -
  \log\frac{\sigma^2}{\hat\sigma^2} - 1.}
This is loss-oriented (lower = better, minimum 0 at a perfect forecast), so
the function negates it: \eqn{S_{QL} = -L_{QL}}.

Literature note: some sources define QLIKE as
\code{log(sigma2_hat) + sigma2 / sigma2_hat}, which differs by constants from
the form above. Here the loss is normalised to have minimum 0 and is then
negated for positive orientation.
}
\section{Unbounded below}{

QLIKE is unbounded below. It should not be used directly with the
finite-sample bounded-difference confidence sequences or e-processes.
Use \code{cs_asymptotic()} for QLIKE-based confidence sequences, or use
\code{eprocess_predictable()} only when genuine ex ante predictable bounds are
available. QLIKE is not compatible with the Winkler construction because
Winkler scores are restricted to binary outcomes and probability forecasts.
}

\examples{
sigma2_hat <- c(1.0, 1.5, 2.0)
sigma2 <- c(1.1, 1.4, 2.2)
qlike_score(sigma2_hat, sigma2)

}
