Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
dynare
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Gauthier Vermandel
dynare
Commits
d554b797
Verified
Commit
d554b797
authored
2 years ago
by
Sébastien Villemot
Browse files
Options
Downloads
Plain Diff
Merge branch 'occ_test' of git.dynare.org:JohannesPfeifer/dynare
Ref. !2103
parents
cce27106
67ba8127
Branches
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
tests/occbin/model_irrcap_twoconstraints/dynrbc_common.inc
+12
-12
12 additions, 12 deletions
tests/occbin/model_irrcap_twoconstraints/dynrbc_common.inc
with
12 additions
and
12 deletions
tests/occbin/model_irrcap_twoconstraints/dynrbc_common.inc
+
12
−
12
View file @
d554b797
...
...
@@ -30,7 +30,7 @@ steady;
%
Option
=
2
:
random
simulation
@
#for option_val in [1, 2]
option
=@
{
option_val
};
%%%%%%%%%%%%%%%%
Inputs
stop
here
%%%%%%%%%%%%%%%%%%%%%
...
...
@@ -41,28 +41,28 @@ if option==1
periods
1
:
9
,
10
,
50
,
90
,
130
,
131
:
169
;
values
-
0.0001
,
-
0.01
,
-
0.02
,
0.01
,
0.02
,
0
;
end
;
elseif
option
==
2
nperiods
=
9
0
;
nperiods
=
4
0
;
randn
(
'seed'
,
1
);
shockssequence
=
1
*
randn
(
nperiods
,
1
)
*
0.02
;
shockssequence
=
1
*
randn
(
nperiods
,
1
)
*
0.02
;
shocks
(
surprise
,
overwrite
);
var
erra
;
periods
1
:
9
0
;
periods
1
:
4
0
;
values
(
shockssequence
);
end
;
end
%
set
inputs
%
set
inputs
occbin_setup
(
smoother_debug
);
occbin_solver
(
simul_debug
,
simul_periodic_solution
,
simul_periods
=
200
,
simul_maxit
=
300
,
simul_curb_retrench
,
simul_check_ahead_periods
=
300
);
occbin_write_regimes
(
filename
=
'test'
,
periods
=
[
1
:
9
0
]);
occbin_write_regimes
(
filename
=
'test'
,
periods
=
[
1
:
4
0
]);
%%
Modify
to
plot
IRFs
%%
Modify
to
plot
IRFs
titlelist
=
char
(
'c'
,
'lambdak'
,
'k'
,
'i'
,
'a'
);
percent
=
'Percent'
;
value
=
'value'
;
...
...
@@ -85,7 +85,7 @@ occbin_graph(noconstant) c erra lambdak k i a k;
end
;
save
(
'datasim.mat'
,
'c'
);
varobs
c
;
occbin_solver
(
simul_periods
=
200
,
simul_maxit
=
200
,
simul_curb_retrench
,
simul_check_ahead_periods
=
200
);
occbin_setup
(
smoother_periods
=
200
,
smoother_maxit
=
200
,
smoother_curb_retrench
,
smoother_check_ahead_periods
=
200
);
calib_smoother
(
datafile
=
datasim
);
...
...
@@ -110,4 +110,4 @@ occbin_graph(noconstant) c erra lambdak k i a k;
line2
=
100
*
[
oo_
.
occbin
.
linear_smoother
.
SmoothedVariables
.
c
-
oo_
.
occbin
.
endo_ss
.
c
,
oo_
.
occbin
.
linear_smoother
.
SmoothedVariables
.
lambdak
/
100
,
oo_
.
occbin
.
linear_smoother
.
SmoothedVariables
.
k
-
oo_
.
occbin
.
endo_ss
.
k
,
oo_
.
occbin
.
linear_smoother
.
SmoothedVariables
.
i
-
oo_
.
occbin
.
endo_ss
.
i
,
oo_
.
occbin
.
linear_smoother
.
SmoothedVariables
.
a
-
oo_
.
occbin
.
endo_ss
.
a
,
oo_
.
occbin
.
linear_smoother
.
SmoothedShocks
.
erra
/
100
];
occbin
.
make_chart
(
titlelist
,
legendlist
,
figtitle
,
ylabels
,
cat
(
3
,
line1
,
line2
));
@
#endif
@
#endfor
\ No newline at end of file
@
#endfor
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment