Commit 0a8604c045d35b96abd8845c948490cf4ecc7e6d

Authored by Jürgen Knödlseder
1 parent d0742fe7

Update reference documentation for csspec.

doc/source/reference_manual/csspec.rst
... ... @@ -10,23 +10,39 @@ Synopsis
10 10 --------
11 11  
12 12 This script computes the source spectrum by fitting a model in a given set
13   -of energy bins. The model fit per energy bin is performed using :doc:`ctlike`
  13 +of spectral bins. The model fit per spectral bin is performed using :doc:`ctlike`
14 14 and the script provides the possibility to fix sources other than the
15 15 source of interest (hidden parameter ``fix_srcs``) or to fix the background
16 16 model component(s) (hidden parameter ``fix_bkg``). The script computes the
17   -source flux and its uncertainty in each energy bin, as well as the significance
18   -of the source detection. Optionally, it also computes an upper flux limit
19   -that is particularily useful in case that the source is not significantly
20   -detected within an energy bin (hidden parameter ``calc_ulim``). The script
21   -works on both, binned and unbinned observation containers. In case of binned input,
22   -the script will determine from the ``enumbins`` parameter, which energy layers
23   -of the input cube will be merged for one spectral bin. Of course, the script
24   -cannot create more spectral bins as available energy bins in the cube.
25   -Also note that for the moment, the Npred column in the output file is not
26   -filled for binned analyses.
  17 +source flux and its uncertainty in each spectral bin, as well as the
  18 +significance of the source detection. Optionally, it also computes an upper
  19 +flux limit that is particularily useful in case that the source is not
  20 +significantly detected within a spectral bin (hidden parameter ``calc_ulim``).
  21 +
  22 +The script works on binned and unbinned data.
  23 +
  24 +For unbinned data, the spectral binning is either defined by a FITS file
  25 +containing the energy boundaries of each bin (option ``ebinalg=FILE``) or
  26 +as ``enumbins`` bins spread linearly (option ``ebinalg=LIN``) or
  27 +logarithmically (option ``ebinalg=LOG``) from a minimum energy given by
  28 +``emin`` to a maximum energy given by ``emax``.
  29 +
  30 +For binned data, all energy bins within the counts cube that overlap with
  31 +the energy range spanned by ``emin`` and ``emax`` are considered. The number
  32 +of spectral bins is only approximately determined by the ``enumbins`` parameter.
  33 +Naturally, the script cannot create more spectral bins than the number of
  34 +energy bins that are available in the cube. Also, in case that ``enumbins``
  35 +is smaller than the number of energy bins in the cube, the script will fit
  36 +several layers of the counts cube for each spectral bin. The number of
  37 +layers fit is determined by the total number of energy bins divided by the
  38 +``enumbins`` parameter.
27 39  
28 40 On output, the script will provide a FITS file with the fitted source
29   -spectrum.
  41 +spectrum in form of a binary table. Each row corresponds to a spectral bin.
  42 +The columns are the mean as well as the boundaries of the spectral bin,
  43 +the fitted flux and flux error, the Test Statistics value (option
  44 +``calc_ts=yes``), the upper flux limit (option ``calc_ulim=yes``) and the
  45 +predicted number of events (only for unbinned data).
30 46  
31 47  
32 48 General parameters
... ... @@ -70,11 +86,14 @@ General parameters
70 86 Upper energy limit of events (in TeV).
71 87  
72 88 ``enumbins [integer]``
73   - Number of energy bins (0=unbinned).
  89 + Number of energy bins.
74 90  
75   -``(ebinalg = LOG) <FILE|LIN|LOG> [string]``
  91 +``ebinalg <FILE|LIN|LOG> [string]``
76 92 Algorithm for defining energy bins.
77 93  
  94 +``ebinfile [file]``
  95 + Name of the file containing the energy bin definition.
  96 +
78 97 ``(calc_ts = yes) [boolean]``
79 98 Compute TS for each spectral point?
80 99  
... ...