How to determine Confidence Interval of each Parameter Estimation results of the GARCH model through fminsearch syntax?
11 views (last 30 days)
Show older comments
I doing the estimation of the parameters of the GARCH model through this data and syntax below where the rv is realized volatility and then I want to know the standars error and the P-value for each parameter estimation results but I think I must to know the confidence interval of these result parameter estimation first. I hope and I'm so glad if one can help me to solve this problem. Thank You.
Y65 = xlsread("Y65",1,"A2:A89");
n = length(Y65);
rv = [];
moving_window = 5;
for i = 1:n-moving_window+1
rv(i) = var(Y65(i:i+moving_window-1));
end
Y65_1 = Y65(moving_window:end)';
logL = @(theta) -(sum((log(1./(sqrt(2.*pi.*(theta(1)+theta(2).*...
Y65_1(1:end-1).^2+theta(3).*rv(1:end-1)))))-(1./2).*...
(Y65_1(2:end)./(sqrt(theta(1)+theta(2).*...
Y65_1(1:end-1).^2+theta(3).*rv(1:end-1)))).^2)));
theta_0 = [0.99 0.3 0.3];
[theta_hat NegLL] = fminsearch(logL, theta_0);
beta_0 = theta_hat(1)
beta_1 = theta_hat(2)
beta_2 = theta_hat(3)
-NegLL
0 Comments
Answers (1)
Vanshika Vaishnav
on 7 Mar 2023
The 'fminsearch' function is a black box, unconstrained nonlinear solver. This means that no assumptions about the problem are made and 'fminsearch' is unaware that it is solving a curve-fitting problem. As a result, the solver returns only basic information. This means that confidence intervals will need to be calculated by the user. If you would like to use 'fminsearch' for curve fitting, a couple of resources on how to manually compute confidence intervals can be found here:
0 Comments
See Also
Categories
Find more on Conditional Variance Models in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!