Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Johannes Pfeifer
dynare
Commits
50e80fe4
Commit
50e80fe4
authored
Feb 16, 2021
by
Marco Ratto
Browse files
write xls output in Output subdir
parent
f592cca5
Changes
1
Hide whitespace changes
Inline
Side-by-side
matlab/WriteShockDecomp2Excel.m
View file @
50e80fe4
...
...
@@ -28,6 +28,8 @@ function WriteShockDecomp2Excel(z,shock_names,endo_names,i_var,initial_date,Dyna
% You should have received a copy of the GNU General Public License
% along with Dynare. If not, see <http://www.gnu.org/licenses/>.
OutputDirectoryName
=
CheckPath
(
'Output'
,
DynareModel
.
dname
);
SteadyState
=
zeros
(
DynareModel
.
endo_nbr
,
1
);
fig_mode
=
''
;
fig_mode1
=
''
;
...
...
@@ -118,9 +120,9 @@ for j=1:nvar
fig_name1
=
strrep
(
fig_name1
,
'.'
,
''
);
if
~
ismac
[
STATUS
,
MESSAGE
]
=
xlswrite
([
DynareModel
.
fname
,
'_shock_decomposition'
,
fig_mode
,
fig_name1
],
d0
,
endo_names
{
i_var
(
j
)});
[
STATUS
,
MESSAGE
]
=
xlswrite
([
OutputDirectoryName
,
filesep
,
DynareModel
.
fname
,
'_shock_decomposition'
,
fig_mode
,
fig_name1
],
d0
,
endo_names
{
i_var
(
j
)});
else
writetable
(
cell2table
(
d0
),
[
DynareModel
.
fname
,
'_shock_decomposition'
,
fig_mode
,
fig_name1
'.xls'
],
'Sheet'
,
endo_names
{
i_var
(
j
)},
'WriteVariableNames'
,
false
);
writetable
(
cell2table
(
d0
),
[
OutputDirectoryName
,
filesep
,
DynareModel
.
fname
,
'_shock_decomposition'
,
fig_mode
,
fig_name1
'.xls'
],
'Sheet'
,
endo_names
{
i_var
(
j
)},
'WriteVariableNames'
,
false
);
end
warning
on
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment