Fermi Solar Data Analysis Workshop at GSFC, August 22-23, 2012
Additions and bug fixes have been made since SSW was installed in the FermiVM. Please follow the instructions here to update SSW in the FermiVM.
These instructions will work even it you don't update, but some new features won't be available
Open Terminal (click Terminal icon on left of FermiVM home screen) In terminal, type cd,'ospex'
sswidl (sswidl starts an SSWIDL command line session, sswidlde opens the SSW
IDLDE GUI) |
|
In SSWIDL, type o=ospex() |
Click File / Select Input | |
Click Browse / On remote sites | |
In 'Time Selection...' widget, click 'Flare Selection' | |
In flare list, Scroll down and click flare 100612_0054 | |
Click Accept | |
In 'Time Selection...' widget, click Search | |
Highlight b0 .pha and .rsp2 files (first two in list) | |
Click 'Accept and Close' | |
In 'Input Options' widget, modify Start and End time to 12-Jun-2010 00:35:00 and 01:35:00 | |
Click 'Plot Time Profile' | |
Zoom in by left-clicking and dragging in plot | |
Unzoom by single left-clicking in plot | |
Right-click to show coordinates of point |
Command line equivalent:set, spex_specfile= '/home/fermiuser/ospex/glg_cspec_b0_100612_v03.pha' o-> set, spex_accum_time= ['12-Jun-2010 00:35:41.457', '12-Jun-2010 01:34:08.328']o-> set, spex_drmfile= '/home/fermiuser/ospex/glg_cspec_b0_bn100612_0054_038_v00.rsp2'o -> plot_time, spex_unit='flux' or o -> xinput to start data input selection widget |
Click File / Select Background | |
In Background Options widget, click Change | |
New widget pops up with instructions | |
Left click in time profile plot at ~00:45, right click at ~00:49 | |
Click 'Accept and Close' in 'Select Time ...' widget |
Command line equivalent:set, spex_bk_time_interval=['12-Jun-2010 00:45:33.605', '12-Jun-2010 00:49:55.753'] or o -> xbk to start background selection widget |
Click File / Select Fit Options and Do Fit | |
Zoom in on time profile | |
In Fit widget, click 'Change Fit Intervals'; | |
In plot left-click at ~00:55:51, right click at ~00:56:02 | |
Click 'Accept and Close' in 'Select Time...' widget | |
In Fit widget, click 'Change' next to 'Energy range to Fit' | |
In plot, left-click at ~250, right-click at ~20000. | |
Click 'Accept and Close' in 'Select Energy...' widget | |
In Fit widget, set 'Systematic Uncert' to 0.0 |
Command line equivalent:set, spex_fit_time_interval= ['12-Jun-2010 00:55:51.086', '12-Jun-2010 00:56:02.351'] o-> set, spex_erange= [250.77327D, 19756.840D]o-> set, spex_uncert= 0.00000or o -> xfit to start fit options widget |
Click 'Do Fit' (if button doesn't show, use scroll bar on right of widget) | |
In Fit Function Setup widget, click 'Delete comp' to right of vth component | |
Click pull-down menu for components (to right of 'Choose:') | |
Select thick2, click Add Change parameter 1 to 1.3, parameter 2 to 300, and parameter 3 to 4.2 |
|
Select template, click Add In template box, click 'Keywords' pull-down menu and click nuc2 |
|
Select line, click Add Change parameter 0 to 0.1, parameter 1 to 2223., and parameter 3 to 0.5 |
|
Select another line, click Add Change parameter 0 to 0.1, parameter 1 to 511, and parameter 3 to 1.0 |
|
Select a third line, click Add Change parameter 0 to .01, parameter 1 to 15000., and parameter 3 to 100. |
|
Current fit function should be 'thick2+template+line+line+line' | |
Click Plot All |
Command line equivalent:set, fit_function= 'thick2+template+line+line+line' o-> set, fit_comp_params= [0.667175, 1.34547, 289.761, 4.24975, 11.6834, 320000., $ 1.94644, 0.118307, 2223.00, 0.500000, 0.162568, 511.000, 1.00000, 0.0258109, 15000.0, 100.000]o-> set, fit_comp_spectrum= ['', 'nuc2', '', '', '']o-> set, fit_comp_model= ['', '', '', '', '']o-> set, fit_comp_free_mask= [1B, 1B, 1B, 1B, 1B, 0B, 1B, 1B, 0B, 0B, 1B, 0B, 0B, 1B, 0B, 0B]o-> plot_spectrum, spex_unit='flux', /bksub, /show_fit |
Click Fit at bottom of 'Fit Function Setup' widget | |
When finished fitting, click Accept / and Store Fit... button. |
Command line equivalent:dofit |
In Fit widget: Click 'Show Fit', 'Show Error', and 'Plot Spectrum in Fit Intervals' Click 'Show Fit Summary' |
|
Click File / Plot Fit Results Select an item on right and click 'Plot' Since we only fit one time interval, items on left can't be plotted as a function of time |
Command line equivalent: o->plot_spectrum, spex_unit='flux', /bksub, /show_fit
o->fitsummary
o -> plot_summ, xplot='energy', yplot='resid'
o -> plot_summ, xplot='energy', yplot='data_photon_flux', /overlay_model, /show_error
or o -> xfitview to start fit results viewing widget
Click File / Write Script / and Fit Results
Command line equivalent:
|
Prepared scripts and fit results files are stored in the ospex directory of the FermiVM for two cases:
The single time interval at the peak of the event as described in the step-by-step instructions above, and | |
6 time intervals during the rise, peak, and decay of the event. |
To run the script and import the fit results for the 6 interval case, type the following in SSWIDL:
cd,'ospex'
Run script by calling it directly (the ospex object reference, o, is returned and the GUI is started):
ospex_script_11_jul_2012_6int, o=o
or start ospex, and click button to run the script:
o=ospex()
Click File / 'Set Parameters from Script' / 'Initialize All Parameters First'
Navigate to script called ospex_script_11_jul_2012_6int.pro
This scripts sets up the OSPEX parameters as they were when the fits were performed, reads in the FITS file containing the fit results for the 6 intervals, and brings up the OSPEX GUI.
Click File / Plot Fit Results
Select any item on the left and plot as a function of time,
or any item on the right and plot as a function of energy.
To delete and clean up after the ospex object, type
destroy, o
To exit IDL, type
exit
Kim Tolbert
Last Modified:
20-Aug-2012