arch.univariate.StudentsT.loglikelihood¶
-
StudentsT.loglikelihood(parameters: Sequence[float] | ndarray | Series, resids: ndarray | DataFrame | Series, sigma2: ndarray | DataFrame | Series, individual: bool =
False
) float | ndarray [source]¶ Computes the log-likelihood of assuming residuals are have a standardized (to have unit variance) Student’s t distribution, conditional on the variance.
- Parameters:¶
- parameters: Sequence[float] | ndarray | Series¶
Shape parameter of the t distribution
- resids: ndarray | DataFrame | Series¶
The residuals to use in the log-likelihood calculation
- sigma2: ndarray | DataFrame | Series¶
Conditional variances of resids
- individual: bool =
False
¶ Flag indicating whether to return the vector of individual log likelihoods (True) or the sum (False)
- Returns:¶
ll – The log-likelihood
- Return type:¶
Notes
The log-likelihood of a single data point x is
\[\ln\Gamma\left(\frac{\nu+1}{2}\right) -\ln\Gamma\left(\frac{\nu}{2}\right) -\frac{1}{2}\ln(\pi\left(\nu-2\right)\sigma^{2}) -\frac{\nu+1}{2}\ln(1+x^{2}/(\sigma^{2}(\nu-2)))\]where \(\Gamma\) is the gamma function.