⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 nigest.m

📁 Modeling and Forecasting Electricity Loads and Prices: A Statistical Approach" by Rafa&#322 Weron, p
💻 M
字号:
function [params,fval,exitflag,iterations]=nigest(x,x0);
%NIGEST Estimate parameters of the NIG distribution.
%   PARAMS=NIGEST(X) returns the maximum likelihood estimates of the NIG 
%   distribution parameters PARAMS=[ALPHA,BETA,DELTA,MU] for a data vector 
%   X. The estimates are computed numerically using the FMINSEARCH simplex 
%   optimization routine.
%   [PARAMS,FVAL,EXITFLAG,ITERATIONS]=NIGEST(X,X0) additionally allows to 
%   specify the initial estimates supplied to FMINSEARCH (default value: 
%   [0.5,0,1]) and returns the value of the objective function FVAL, an 
%   EXITFLAG that describes the exit condition of FMINSEARCH (type "help
%   FMINSEARCH" in the command line for details) and the numer of
%   ITERATIONS performed to reach the result.
%
%   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;
% Set initial parameter estimates
if nargin==1
    x0=[0.5,0,1];
end;
warning off
% Run optimization
[params,fval,exitflag,output] = fminsearch('nigloglik',x0,optimset('MaxFunEvals',1e12),x);
params = [params,mu];
iterations = output.iterations;
warning on

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -