aciscalsrc-fit - Extract the spectrum from an event 1 FITS file. Fit the resulting spectrum to a gaussian by minimizing chi-square and c-statistics extract spectra from events, then fit models to the spectra.
aciscalsrc-fit -f file -i ccd_id -t tag -N nameofLines [ -a listofascagrade (0,2,3,4,6) | -g listoffltgrades ] [ -F [ chisqr, cstat ] ] [ -c chunks (32,256) ] [ -C colToExtract (pha) ] [ -d ] [ -D listofworkstations ] [ -h ] [ -l boxcarlength ] [ -m minPixValue (0) ] [ -M fitMethod ] [ -n listofnodestoextract ] [ -o ] [ -s ] [ -u ]
For the purpose of the description of the output files, it will be assumed that the user had entered the following command:
aciscalsrc-fit -f data.fits -i 3 -t myprefix -c 32 -n 2 -N Al,Ti,Mn
Given the command above, all output files shall have a prefix of the form:
myprefix-i3-n2
The consolidated (all the 32 chunks) fitted-parameters of the model by minimizing chi-square and cstatistics are in the files:
myprefix-i3-n2-Al-Ti-Mn-chisqr.rdb
and
myprefix-i3-n2-Al-Ti-Mn-cstat.rdb
respectively.
The consilidated plots of the fitted chunks are in the files:
myprefix-i3-n2-Al-Ti-Mn.cps
and
myprefix-i3-n2-Al-Ti-Mn-residuals.cps
For each of the chunk, the output files files shall have the prefix, say for the chunk 1 through 32:
myprefix-i3-n2-y0001_0032
The consolidated results of the lines are in the files:
myprefix-i3-n2-y0001_0032-Al-Ti-Mn-chisqr.rdb myprefix-i3-n2-y0001_0032-Al-Ti-Mn-cstat.rdb myprefix-i3-n2-y0001_0032-Al-Ti-Mn-residuals.cps myprefix-i3-n2-y0001_0032-Al-Ti-Mn.cps
For each of the emission-lines given in the command line option -N. The following files shall be produced:
myprefix-i3-n2-y0001_0032-Energy-chisqr.rdb myprefix-i3-n2-y0001_0032-Energy-cstat.rdb myprefix-i3-n2-y0001_0032-Energy-modelvsrawdata.rdb myprefix-i3-n2-y0001_0032-Energy-paramdef.rdb myprefix-i3-n2-y0001_0032-Energy.cps
where Energy is one of the emission lines (Al, Ti, or Mn) given in the -N command line option. The files are: the fitted parameters by minimizing chi-square, c-statistics, an rdb table containing the model versus raw-data of the data, the parameter definition used to fit the line and the plot of the emission line, respectively.
The file:
myprefix-i3-n2-y0001_0032-guess.rdb
is the output of the program findline which is used as the starting point for the parameters to the emission lines.
The raw data for a chunk is in:
myprefix-i3-n2-y0001_0032.rdb
The rdb file
myprefix-i3-n2-filename.rdb
contains the commands used to run the script fit_the_lines.
The options are :
aciscalsrc-fit -h
aciscalsrc-fit -f data.fits -i 3 -t prefix -c 32 -n 3 -N a,b,c
aciscalsrc-fit -f data.fits -i 3 -t prefix -c 32 -n 3 -N a,b,c -l 3
aciscalsrc-fit -f data.fits -i 3 -t prefix -c 32 -n 3 -N a,b,c -l 3 -m 5
aciscalsrc-fit -f data.fits -i 3 -t prefix -c 32 -n 3 -N a,b,c -l 3 -m odrpack
NOTE: previous user(s) indicate that OptSolvePowell, while slower than
the default method, provides more reliable fits to line width.
aciscalsrc-fit -f data.fits -i 3 -t prefix -c 32 -n 3 -N a,b,c
aciscalsrc-fit -f data.fits -i 3 -t prefix -c 32 -n 3 -N a,b,c
aciscalsrc-fit -f data.fits -i 3 -t prefix -c 32 -n 3 -N a,b,c
aciscalsrc-fit -u
aciscalsrc-fit -v
There have been some issues with the quality of the line fits using the default method. It has been found that the OptSolvePowel method, while slower, will provide better fits to the line width, -M OptSolvePowell.
There have been issues in the past with fitting the peaks of lines due to multiple lines blending together. If this seems to be the case, consider increasing the cut off limit, -m <some larger number>