Octave can create PDF files

time-shift
Sébastien Villemot 2012-06-07 18:29:00 +02:00
parent 35a2f38d6a
commit 6cc3be7252
1 changed files with 8 additions and 9 deletions

View File

@ -33,16 +33,15 @@ function dyn_saveas(h,fname,DynareOptions)
if find(strcmp('eps',DynareOptions.graph_format))
eval(['print -depsc2 ' fname '.eps']);
end
if ~exist('OCTAVE_VERSION')
if find(strcmp('pdf',DynareOptions.graph_format))
eval(['print -dpdf ' fname]);
end
if find(strcmp('fig',DynareOptions.graph_format))
if DynareOptions.nodisplay
set(h, 'Visible','on');
end
saveas(h,[fname '.fig']);
if find(strcmp('pdf',DynareOptions.graph_format))
eval(['print -dpdf ' fname]);
end
if ~exist('OCTAVE_VERSION') ...
&& find(strcmp('fig',DynareOptions.graph_format))
if DynareOptions.nodisplay
set(h, 'Visible','on');
end
saveas(h,[fname '.fig']);
end
if DynareOptions.nodisplay
close(h);