tset current figure, add doc - cosmo - front and backend for Markov-Chain Monte Carlo inversion of cosmogenic nuclide concentrations (HTM) git clone git://src.adamsgaard.dk/cosmo (DIR) Log (DIR) Files (DIR) Refs (DIR) README (DIR) LICENSE --- (DIR) commit 2fed4994998bb30b81632002d8dd4d664e00db65 (DIR) parent c279c1bb3b89912e64fc67df00588008acbc2d39 (HTM) Author: Anders Damsgaard <anders.damsgaard@geo.au.dk> Date: Wed, 26 Aug 2015 16:33:15 +0200 set current figure, add doc Diffstat: M matlab/figure_save_multiformat.m | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) --- (DIR) diff --git a/matlab/figure_save_multiformat.m b/matlab/figure_save_multiformat.m t@@ -1,7 +1,12 @@ -function figure_save_multiformat(fig, formats) +function figure_save_multiformat(fig, basename, formats) + +%% figure_save_multiformat.m +% save a figure in multiple formats with a single function call. +% Example: +% figure_save_multiformat(gcf, 'first_plot', ['fig', 'png', 'pdf']) + +figure(fig); % set current figure -%% save figures -basename = 'plot'; for i=1:length(formats) format = formats(i); if strcmp(format, fig)