Package pysynphot :: Module spectrum :: Class FileSpectralElement
[hide private]
[frames] | no frames]

Class FileSpectralElement

source code


spec = FileSpectrum(filename (FITS or ASCII), throughputname=column name containing throughput (for FITS tables only), keepneg=True to override the default behavior of setting negative throughput values to zero)

Instance Methods [hide private]
 
__init__(self, filename, thrucol=None)
Create a bandpass from a file.
source code
 
_readThroughputFile(self, filename, throughputname) source code
 
_readFITS(self, filename, throughputname) source code
 
_readASCII(self, filename)
Ascii files have no headers.
source code

Inherited from TabularSpectralElement: __str__, getHeaderKeywords

Inherited from TabularSpectralElement (private): _reverse_wave

Inherited from SpectralElement: GetThroughput, GetWaveSet, ToInternal, __call__, __mul__, __rmul__, convert, resample, taper, unitResponse, validate_units, writefits

Inherited from Integrator: trapezoidIntegration, validate_fluxtable, validate_wavetable

Inherited from Integrator (private): _columnsFromASCII

Inherited from object: __delattr__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__

Properties [hide private]

Inherited from SpectralElement: throughput, wave

Inherited from object: __class__

Method Details [hide private]

__init__(self, filename, thrucol=None)
(Constructor)

source code 

Create a bandpass from a file.

Parameters:
  • filename (string) - FITS or ASCII file containing the bandpass
  • thrucol (string) - Column name specifying the throughput (FITS only)
Overrides: object.__init__

_readFITS(self, filename, throughputname)

source code 
Overrides: TabularSpectralElement._readFITS

_readASCII(self, filename)

source code 

Ascii files have no headers. Following synphot, this routine will assume the first column is wavelength in Angstroms, and the second column is throughput in Flam.

Overrides: TabularSpectralElement._readASCII