NAME gtmktime - Create Good Time Intervals (GTIs) based on selections made using the spacecraft data file variables. USAGE gtmktime scfile filter roicut evfile outfile DESCRIPTION gtmktime is used to update the Good Time Intervals (GTI) extension and make cuts based on spacecraft parameters contained in the Pointing and Livetime History (spacecraft) FITS file. A Good Time Interval is a time range when the data can be considered valid. The GTI extension contains a list of these GTIs for the file. The sum of the entries in the GTI extension of a file corresponds to the time intervals when the data in the file is "good". In the case of the LAT data, the GTIs are the list of times that the LAT was collecting data over the time range you selected. Tools use the GTIs for exposure calculations. The gtmktime tool reads the spacecraft data file and, based on specified cuts, creates a set of GTIs. These are then combined (logical and) with the existing GTIs in the event file, and all events outside this new set of GTI are removed from the file. New GTIs are then written to the GTI extension of the new file. The gtmktime tool will be most commonly applied to event data; and by default the event data will be filtered according to the GTIs that are created. This tool may also be used to update GTIs in other files such as those created by gtltcube (see the gtltcube help). The cuts can be made on any field in the spacecraft data file. The default is to select times when the spacecraft is not in the Southern Atlantic Anomaly (SAA), i.e. "IN_SAA!=T". The cuts are made using C-style relational syntax like for example: ! (not),&& (and), || (or), != (different), >, <, >=, <=, abs(), cos(), sin(), etc. Other kinds of cuts on the data could be made using the gtselect tool. See the gtselect documentation for further explanation. PARAMETERS scfile [file] Spacecraft data file containing information such as the spacecraft pointing as a function of time. This file could be generated by gtorbsim for simulated observations (see the gtorbsim help for further explanation) or for real observations, it can be obtained from the FERMI Science Support Center (FSSC) website. (sctable = SC_DATA) [string] Spacecraft data extension. This is a hidden parameter. The default value is SC_DATA. filter [= DATA_QUAL==1 && LAT_CONFIG==1 && ABS(ROCK_ANGLE)<52] [string] This is the filter expression. The cuts are make using C-style relational syntax like for example: ! (not),&& (and), || (or), != (different), >, <, >=, <=, abs(), cos(), sin(), etc. roicut [= yes] [bool] Apply ROI-based zenith angle cut to exclude times where the region of interest is outside the field of view.If "yes", then the code will construct a filter string expression of the form angsep(RA_ZENITH,DEC_ZENITH,RA_ROI,DEC_ROI)