|
427 | 427 | "cell_type": "markdown", |
428 | 428 | "metadata": {}, |
429 | 429 | "source": [ |
430 | | - "The data file with all the cuts described above is provided in this [link](https://fermi.gsfc.nasa.gov/ssc/data/analysis/scitools/data/BinnedLikelihood/3C279_binned_gti.fits). A more detailed discussion of data selection can be found in the [Data Preparation](https://fermi.gsfc.nasa.gov/ssc/data/analysis/scitools/data_preparation.html) analysis thread.\n", |
| 430 | + "The data file with all the cuts described above is provided in this [link](https://fermi.gsfc.nasa.gov/ssc/data/analysis/scitools/data/BinnedLikelihood/3C279_binned_gti.fits). A more detailed discussion of data selection can be found in the [Data Preparation](https://github.com/fermi-lat/AnalysisThreads/blob/master/DataSelection/2.DataPreparation/data_preparation.ipynb) analysis thread.\n", |
431 | 431 | "\n", |
432 | 432 | "To view the DSS keywords in a given extension of a data file, use the **gtvcut** tool and review the data cuts on the EVENTS extension. This provides a listing of the keywords reflecting each cut applied to the data file and their values, including the entire list of GTIs. (Use the option `suppress_gtis=no` to view the entire list.)" |
433 | 433 | ] |
|
507 | 507 | "\n", |
508 | 508 | "It is important to inspect your data prior to proceeding to verify that the contents are as you expect. A malformed data query or improper data selection can generate a non-circular region, or a file with zero events. By inspecting your data prior to analysis, you have an opportunity to detect such issues early in the analysis.\n", |
509 | 509 | "\n", |
510 | | - "A more detailed discussion of data exploration can be found in the [Explore LAT Data](https://fermi.gsfc.nasa.gov/ssc/data/analysis/scitools/explore_latdata.html) analysis thread." |
| 510 | + "A more detailed discussion of data exploration can be found in the [Explore LAT Data](https://github.com/fermi-lat/AnalysisThreads/blob/master/DataSelection/3.ExploreLATData/explore_latdata.ipynb) analysis thread." |
511 | 511 | ] |
512 | 512 | }, |
513 | 513 | { |
|
629 | 629 | "\n", |
630 | 630 | "The [gtlike](https://fermi.gsfc.nasa.gov/ssc/data/analysis/scitools/help/gtlike.txt) tool reads the source model from an XML file. The model file contains your best guess at the locations and spectral forms for the sources in your data. A source model can be created using the [model editor](https://fermi.gsfc.nasa.gov/ssc/data/analysis/scitools/help/modeleditor.txt) tool, by using the user contributed package [LATSourceModel](https://github.com/physicsranger/make4FGLxml) (also available at the [user-contributed tools](https://fermi.gsfc.nasa.gov/ssc/data/analysis/user/) page), or by editing the file directly within a text editor. See Section 4 of the the [Unbinned Likelihood](https://github.com/fermi-lat/AnalysisThreads/blob/master/SourceAnalysis/2.UnbinnedLikelihood/likelihood_tutorial.ipynb) tutorial for a brief tutorial on installing this package.\n", |
631 | 631 | "\n", |
632 | | - "Here we cannot use the same source model that was used to analyze six months of data in the [Unbinned Likelihood](https://github.com/fermi-lat/AnalysisThreads/blob/master/SourceAnalysis/2.UnbinnedLikelihood/likelihood_tutorial.ipynb) tutorial, as the 2-year data set contains many more significant sources and will not converge. Instead, we will use the 4FGL-DR4 catalog to define our source model by running [make4FGLxml](https://fermi.gsfc.nasa.gov/ssc/data/analysis/user/), which comes with the LATSourceModel package. To run the tool, you will need to download the current [LAT catalog file](https://fermi.gsfc.nasa.gov/ssc/data/access/lat/14yr_catalog/gll_psc_v32.xml) and place it in your working directory. Then, use the make4FGLxml tool to create an XML model file:" |
| 632 | + "Here we cannot use the same source model that was used to analyze six months of data in the [Unbinned Likelihood](https://github.com/fermi-lat/AnalysisThreads/blob/master/SourceAnalysis/2.UnbinnedLikelihood/likelihood_tutorial.ipynb) tutorial, as the 2-year data set contains many more significant sources and will not converge. Instead, we will use the 4FGL-DR4 catalog to define our source model by running the LATSourceModel package. To run the tool, you will need to download the current [LAT catalog file](https://fermi.gsfc.nasa.gov/ssc/data/access/lat/14yr_catalog/gll_psc_v32.xml) and place it in your working directory. Then, use the make4FGLxml tool to create an XML model file:" |
633 | 633 | ] |
634 | 634 | }, |
635 | 635 | { |
|
717 | 717 | "source": [ |
718 | 718 | "### XML for Extended Sources\n", |
719 | 719 | "\n", |
720 | | - "In some regions, the [make4FGLxml.py](https://fermi.gsfc.nasa.gov/ssc/data/analysis/user/make4FGLxml.py) script may add one or more extended sources to your XML model.\n", |
| 720 | + "In some regions, the make4FGLxml script may add one or more extended sources to your XML model.\n", |
721 | 721 | "\n", |
722 | | - "The script will provide the number of extended sources included in the model. In order to use these extended sources, you will need to downloaded the extended source templates from the [LAT Catalog](https://fermi.gsfc.nasa.gov/ssc/data/access/lat/8yr_catalog/) page (look for \"Extended Source template archive\").\n", |
| 722 | + "The script will provide the number of extended sources included in the model. In order to use these extended sources, you will need to downloaded the extended source templates from the [LAT Catalog](https://fermi.gsfc.nasa.gov/ssc/data/access/lat/14yr_catalog/) page (look for \"Extended Source template archive\").\n", |
723 | 723 | "\n", |
724 | 724 | "Extract the archive in the directory of your choice and note the path to the template files, which have names like `W44.fits` and `VelaX.fits`. You will need to provide the path to the template file to the script before you run it.\n", |
725 | 725 | "\n", |
|
746 | 746 | "source": [ |
747 | 747 | "# 6. Compute livetimes and exposure\n", |
748 | 748 | "\n", |
749 | | - "To speed up the exposure calculations performed by Likelihood, it is helpful to pre-compute the livetime as a function of sky position and off-axis angle. The [gtltcube](https://fermi.gsfc.nasa.gov/ssc/data/analysis/scitools/gtltcube.txt) tool creates a livetime cube, which is a [HealPix](http://healpix.jpl.nasa.gov/) table, covering the entire sky, of the integrated livetime as a function of inclination with respect to the LAT z-axis.\n", |
| 749 | + "To speed up the exposure calculations performed by Likelihood, it is helpful to pre-compute the livetime as a function of sky position and off-axis angle. The [gtltcube](https://raw.githubusercontent.com/fermi-lat/fermitools-fhelp/master/fhelp_files/gtltcube.txt) tool creates a livetime cube, which is a [HealPix](http://healpix.jpl.nasa.gov/) table, covering the entire sky, of the integrated livetime as a function of inclination with respect to the LAT z-axis.\n", |
750 | 750 | "\n", |
751 | | - "Here is an example of how to run [gtltcube](https://fermi.gsfc.nasa.gov/ssc/data/analysis/scitools/gtltcube.txt):" |
| 751 | + "Here is an example of how to run [gtltcube](https://raw.githubusercontent.com/fermi-lat/fermitools-fhelp/master/fhelp_files/gtltcube.txt):" |
752 | 752 | ] |
753 | 753 | }, |
754 | 754 | { |
|
824 | 824 | "\n", |
825 | 825 | "Instead, you should specify the appropriate geometry for the exposure map, remembering that the counts cube used 0.2 degree pixel binning. To do that, enter `none` when asked for a Counts cube.\n", |
826 | 826 | "\n", |
827 | | - "**Note**: If you get a \"`File not found`\" error in the examples below, just put the IRF name in explicitly. The appropriate IRF for this data set is `P8R3_SOURCE_V3`." |
| 827 | + "**Note**: If you get a \"`File not found`\" error in the examples below, just put the IRF name in explicitly. The appropriate IRF for this data set is `P8R3_SOURCE_V3`.\n", |
| 828 | + "\n", |
| 829 | + "**Note**: Users should enter an evtype that is consistent with previous analysis steps." |
828 | 830 | ] |
829 | 831 | }, |
830 | 832 | { |
|
926 | 928 | "source": [ |
927 | 929 | "The all-sky exposure map can be found [here](https://fermi.gsfc.nasa.gov/ssc/data/analysis/scitools/data/BinnedLikelihood/3C279_binned_allsky_expcube.fits).\n", |
928 | 930 | "\n", |
929 | | - "Just as in the [Unbinned Likelihood](https://fermi.gsfc.nasa.gov/ssc/data/analysis/scitools/likelihood_tutorial.html) analysis, the exposure needs to be recalculated if the ROI, zenith angle, time, event class, or energy selections applied to the data are changed. For the binned analysis, this also includes the spatial and energy binning of the 3D counts map (which affects the exposure map as well)." |
| 931 | + "Just as in the [Unbinned Likelihood](https://github.com/fermi-lat/AnalysisThreads/blob/master/SourceAnalysis/2.UnbinnedLikelihood/likelihood_tutorial.ipynb) analysis, the exposure needs to be recalculated if the ROI, zenith angle, time, event class, or energy selections applied to the data are changed. For the binned analysis, this also includes the spatial and energy binning of the 3D counts map (which affects the exposure map as well)." |
930 | 932 | ] |
931 | 933 | }, |
932 | 934 | { |
|
0 commit comments