📄 hyploglik.m
字号:
function y=hyploglik(params,x);
%HYPLOGLIK Hyperbolic log-likelihood function.
% Y=HYPLOGLIK(PARAMS,X) returns the log-likelihood function of the
% hyperbolic distribution with parameters PARAMS = [ALPHA,BETA,DELTA].
% The location parameter MU is computed from the other three parameters
% and the mean of the data vector X.
%
% Reference(s):
% [1] R.Weron (2004) "Computationally intensive Value at Risk
% calculations", in "Handbook of Computational Statistics: Concepts and
% Methods", eds. J.E. Gentle, W. Haerdle, Y. Mori, Springer, Berlin,
% 911-950.
% [2] R.Weron (2007) "Modeling and Forecasting Electricity Loads and
% Prices: A Statistical Approach", Wiley, Chichester.
% Written by Adam Misiorek and Rafal Weron (2006.09.22)
% Copyright (c) 2006 by Rafal Weron
global mu;
alpha = params(1);
beta = params(2);
delta = params(3);
mu = -delta*beta/sqrt(alpha^2-beta^2)*besselk(1+1,delta*sqrt(alpha^2-beta^2))/besselk(1,delta*sqrt(alpha^2-beta^2))+mean(x);
if (delta>0)&(alpha>abs(beta))
y = -sum(log(hyppdf(x,alpha,beta,delta,mu)));
else
y = realmax;
end;
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -