read_pha
- sherpa.astro.io.read_pha(arg, use_errors: bool = False, use_background: bool = False) DataPHA | list[DataPHA][source] [edit on github]
Create a DataPHA object.
Changed in version 4.17.0: Channel numbers that start at 0 are now left as is rather than be renumbered to start at 1.
- Parameters:
- arg
The name of the file or a representation of the file (the type depends on the I/O backend) containing the PHA data.
- use_errorsbool,
optional If the PHA file contains statistical error values for the count (or count rate) column, should it be read in. This defaults to
False.- use_backgroundbool,
optional Should the background PHA data (and optional responses) also be read in and associated with the data set?
- Returns: