Chandra X-Ray Observatory
	(CXC)
Skip to the navigation links
Last modified: December 2009

URL: http://cxc.harvard.edu/ciao/ahelp/tg_bkg.html
AHELP for CIAO 4.9

tg_bkg

Context: tools

Synopsis

Creates a PHA background file for use in XSPEC

Syntax

tg_bkg input_pha2.fits [output_bkg_pha2.fits]

Description

tg_bkg makes a background file that is compatible with XSPEC. Sherpa will be able to use it, but that application can already read the arrays directly from the PHA file. The script sums the BACKGROUND_UP and BACKGROUND_DOWN columns and adjusts the scale factor keyword (BACKSCAL) accordingly. Since it is designed to keep the same format as the PHA file, i.e. the rows in both files correspond to one another, it is a more convenient way of inspecting the background.

Note that since the script updates the BACKFILE keyword, the input file must have write permission. If an output file name is not specified, the script uses the input file name with "_bkg" appended.

It is important to note that these are estimates to the background. Since they are binned adjacent to the spectrum source region, they will have a contribution from the wings of the PSF. They also have a contribution from signal aliased in chipy during the frame shift at the level of (usually) 41 ms frame shift / 3200 ms integration / 1024 rows, or 1.25e-5 times the source rate (HEG+MEG or LEG, all orders). The source count rate at that diffraction angle gets smeared during the frame shift.

Example 1

tg_bkg acisf0145N003_pha2.fits acisf0145N003_bkg_pha2.fits

Create a background file for ObsID 145.

Example 2

tg_bkg acisf00459N002_pha2.fits

Create a background file for ObsID 459. Since an output filename is not given, tg_bkg creates "acisf00459N002_pha2.fits_bkg".

About Contributed Software

This script is not an official part of the CIAO release but is made available as "contributed" software via the CIAO scripts page. Please see the installation instructions page for help on installing the package.

Bugs

There are no known bugs for this tool.

See Also

chandra
eventdef
tools
combine_grating_spectra, detilt, dewiggle, dmtype2split, mktgresp, symmetrize, tg_choose_method, tg_create_mask, tg_findzo, tg_resolve_events, tgdetect, tgdetect2, tgextract, tgextract2, tgidselectsrc, tgmask2reg, tgmatchsrc, tgsplit

Last modified: December 2009
Smithsonian Institute Smithsonian Institute

The Chandra X-Ray Center (CXC) is operated for NASA by the Smithsonian Astrophysical Observatory. 60 Garden Street, Cambridge, MA 02138 USA.   Email:   cxchelp@head.cfa.harvard.edu Smithsonian Institution, Copyright © 1998-2017. All rights reserved.