diff options
author | Aaron LI <aly@aaronly.me> | 2017-11-18 15:38:17 +0800 |
---|---|---|
committer | Aaron LI <aly@aaronly.me> | 2017-11-18 15:38:17 +0800 |
commit | 3f9da58ce86ca6b11789ef6f00b96710df53ada4 (patch) | |
tree | 0bda03a16d1064f12c211e002fc435edab4efba6 /astro | |
parent | b7beb1a6d7abe192c7b97a18ec389b0270af0bc6 (diff) | |
download | atoolbox-3f9da58ce86ca6b11789ef6f00b96710df53ada4.tar.bz2 |
xspec_instlines_mc.tcl: Append time stamp to output files
Diffstat (limited to 'astro')
-rw-r--r-- | astro/xmm/xspec_instlines_mc.tcl | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/astro/xmm/xspec_instlines_mc.tcl b/astro/xmm/xspec_instlines_mc.tcl index dc2d059..7953602 100644 --- a/astro/xmm/xspec_instlines_mc.tcl +++ b/astro/xmm/xspec_instlines_mc.tcl @@ -55,11 +55,11 @@ chatter 5 # Name of this script set script_name "xspec_instlines_mc.tcl" -set date_now [ clock format [ clock seconds ] -format %Y%m%d ] +set time_now [ clock format [ clock seconds ] -format %Y%m%dT%H%M ] # Default output filename to store the Monte Carlo results -set outfile_default "xspec_instlines_mc.${date_now}.csv" +set outfile_default "xspec_instlines_mc.${time_now}.csv" # Default file to log the XSPEC messages (as the screen output is suppressed) -set logfile_default "xspec_instlines_mc.${date_now}.log" +set logfile_default "xspec_instlines_mc.${time_now}.log" # Default number of Monte Carlo times set mc_times_default 1000 @@ -69,9 +69,10 @@ set mc_times_default 1000 # Save current XSPEC fitting results proc save_xspec {} { - set now [ clock format [ clock seconds ] -format %Y%m%d%H%M ] - set xspec_outfile "xspec_saveall.${now}.xcm" + global time_now + set xspec_outfile "xspec_saveall.${time_now}.xcm" save all $xspec_outfile + puts "XSPEC fitting results saved to: $xspec_outfile" } # Print the header line of the given parameters |