Skip to content

Commit 9387737

Browse files
Update scripts (#133)
1 parent 956130e commit 9387737

File tree

2 files changed

+3
-7
lines changed

2 files changed

+3
-7
lines changed

examples/ane.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ y_test = y[401:460]
1010
Random.seed!(123)
1111

1212
# Specify GAS model: a lognormal model with time-varying μ, constant σ, and lags 4 and 12
13-
gas = Model(4, 12, LogNormal, 1.0; time_varying_params=[1])
13+
gas = Model([1, 2, 3, 4], [1, 2, 3, 10, 11, 12], LogNormal, 1.0; time_varying_params=[1])
1414

1515
# Obtain initial parameters to start the GAS recursion
1616
initial_params = dynamic_initial_params(y_train, gas)

examples/cpichg.jl

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -40,14 +40,10 @@ forec.parameter_forecast
4040
forec.observation_scenarios
4141

4242
gas_t = Model(1, 1, TDistLocationScale, 1.0; time_varying_params = [1])
43-
steps_ahead = 50
44-
first_idx = 150
45-
b_t = backtest(gas_t, y, steps_ahead, first_idx)
46-
plot(b_t, "GAS(1, 1) Student t")
47-
4843
gas_t_1_2 = Model(1, 2, TDistLocationScale, 1.0; time_varying_params = [1])
4944
steps_ahead = 50
5045
first_idx = 150
46+
b_t = backtest(gas_t, y, steps_ahead, first_idx)
5147
b_t_1_2 = backtest(gas_t_1_2, y, steps_ahead, first_idx)
52-
plot(b_t, "GAS(1, 1) Student t");
48+
plot(b_t, "GAS(1, 1) Student t")
5349
plot!(b_t_1_2, "GAS(1, 2) Student t"; legend = :topleft)

0 commit comments

Comments
 (0)