Can anyone tell what's wrong with my simulation:
////////////////////////////////////////the Code:
clear all
program define MonteCarlo, rclass
import excel "C:\Users\altal\OneDrive\Desktop\Udemy\ma1.xls x", sheet("ma1") firstrow
quietly gen time =_n
quietly tsset time
scalar a0 = 0.01
scalar alpha = 0.05
scalar beta = 0.6
gen v=rnormal(0,1)
gen h=rnormal(0,1)
generate e=sqrt(h)*v
replace h=a0+(alpha*(v[_n-1]^2)+ beta)*h[_n-1]
arch y, arch(1/1) garch(1/1)
end
simulate _cons [ARCH]L1.arch [ARCH]L1.garch, reps(500): MonteCarlo
summarize _cons [ARCH]L1.arch [ARCH]L1.garch
////////////////////////////////////
thanks in advance
Related Posts with Monte Carlo Simulation to generate garch process
estab problemsHello forum I am having a problem using -estab- to create an rtf.table output for some tabstats. I …
plot the results of a 2sls regression with fixed effectsHello, I want to plot the results of a 2sls regression with fixed effects for different values of a …
Replace when a string variable is longer than 4 charactersDear all, I would like to replace a string variable which is longer than 4 digits with numbers. For…
Dates got omitted due to collinearity in fixed-effects regression modelHello, I run a regression to examine what has an impact on the decision to sell a stock on the stoc…
Cannot Install didregress commandHi all, I am trying to run a regression like the follwoing one: Code: didregress (satis) (procedu…
Subscribe to:
Post Comments (Atom)
0 Response to Monte Carlo Simulation to generate garch process
Post a Comment