PyNeb  1.1.2
PyNeb Reference Manua
_ManageAtomicData Class Reference

Inherits object.

Public Member Functions

def __init__ (self)
 
def includeFitsPath (self)
 
def removeFitsPath (self)
 
def getPredefinedDataFileDict
 
def getAllPredefinedDict (self)
 
def resetDataFileDict (self)
 
def setDataFileDict
 
def addDataFilePath
 
def removeDataFilePath
 
def getAllDataFilePaths (self)
 
def getDirForFile (self, data_file)
 
def printDirForAllFiles (self)
 
def getAllAvailableFiles
 
def getAllPossibleAtoms (self)
 
def getAllAtoms
 
def getDataFile
 
def getDataFullPath
 
def scanDirForDataFiles (self, fits_dir)
 
def setDataFile
 
def printAllSources
 
def addAllChianti (self)
 
def read_gsconf (self)
 
def printPoem
 

Public Attributes

 log_
 
 calling
 
 predefined
 
 ChiantiIONS
 
 Chianti_path
 
 gsconf
 

Constructor & Destructor Documentation

def __init__ (   self)

Member Function Documentation

def addAllChianti (   self)
def addDataFilePath (   self,
  fits_dir = None,
  inPyNeb = False 
)
Add a directory to the list of directories where atomic data files are searched for.

Parameters:
   - fits_dir    directory
   - inPyNeb     Boolean.
def getAllAtoms (   self,
  coll = True,
  rec = False 
)
Return a list of all the atoms (e.g. 'O3') included in the adopted dictionary 
and for which dataFiles are available (a subset of all the ions returned by
the getAllPossibleIons() command)

Parameters:
    - coll     if True (default) includes the Atom objects
    - rec     if True (not the default) includes the RecAtoms
def getAllAvailableFiles (   self,
  atom = None,
  data_type = None 
)
Scan every directory in the list of paths, printing all the *atom*.fits, *atom*.dat,
    *coll*.fits and *rec*.fits files
    
Parameters:
   - atom        atom name
   - data_type   either 'rec', 'atom', 'coll' or 'trc'
def getAllDataFilePaths (   self)
Return the list of directories where atomic data files are searched for.
def getAllPossibleAtoms (   self)
Return the list of all the possible collisional and recombination 
atoms that can be built with the available datafiles (not all of 
them necessarily included in the current atomic file dictionary) 
    
Parameters:
   - atom        atom name
   - data_type   either 'rec', 'atom' or 'coll'
def getAllPredefinedDict (   self)
Return the labels of the available predefined dictionaries of atomic data
def getDataFile (   self,
  atom = None,
  data_type = None,
  warn = True 
)
Return the name of the atomic data file associated to an atom and a type of data, 
which is one of ('atom', 'coll', 'rec').
    
Parameters:
    - atom        selected atom
    - data_type   type of atomic data ('atom', 'coll', 'rec', 'trc')
    - warn        warn if no associated data file is found
def getDataFullPath (   self,
  atom,
  data_type = None,
  warn = True 
)
Return the full path of the atomic data file associated to an atom and a type of data, 
which is one of ('atom', 'coll', 'rec').

Parameters:
    - atom        selected atom
    - data_type   type of atomic data ('atom', 'coll', 'rec', 'trc')
    - warn        warn if no associated data file is found
def getDirForFile (   self,
  data_file 
)
Return the first directory from getDataFilePaths() where a file is found.
If nothing is found, return None.

Parameters:
   - data_file    name of the file
def getPredefinedDataFileDict (   self,
  data_dict = None 
)
Retrieve all predefined dictionaries of atomic data (or a specified one if data_dict is specified)

Parameters:
   - data_dict    name of the dictionary (default: None)
def includeFitsPath (   self)
def printAllSources (   self,
  at_set = None,
  predef = None 
)
Print bibliographic sources of the adopted data sets of a list of atoms.

Usage:
pn.atomicData.printAllSources(['O3', 'Ar4', 'S2'])
pn.atomicData.printAllSources([O, S])
pn.atomicData.printAllSources()

Parameters: 
    - at_set   a list or tuple containing the atoms. If not set, 
       print bibliographic sources for all the atoms in PyNeb's default dictionary
def printDirForAllFiles (   self)
Print the directories where all the files defined in the dictionary of 
    atomic data files are located.
def printPoem (   self,
  yr = 0 
)
Print one of Wiese et al. spectroscopic poems

Parameters:
    - yr     publication year. If no valid year is given, random print
def read_gsconf (   self)
def removeDataFilePath (   self,
  fits_dir = None 
)
Remove a directory from the list of directories where atomic data files are searched for.

Parameters:
   - fits_dir    name of the directory to be removed
def removeFitsPath (   self)
def resetDataFileDict (   self)
Reset the DataFileDict to the default value. This value is in defaultDict
def scanDirForDataFiles (   self,
  fits_dir 
)
Scan a directory and associate any file named x_i_type_ref.fits to the atom Xi (i in roman), 
type being one of ('atom', 'coll', 'rec').
The directory must have been registered before using addDataFilePath(fits_dir)

Parameters:
    - fits_dir        directory name
def setDataFile (   self,
  data_file = None,
  atom = None,
  data_type = None 
)
Associate an atomic data file to an atom and a type of data, which is one of 
    ('atom', 'coll', 'rec', 'func').

Usage:
    pn.atomicData.setDataFile('cl_iii_atom_M83-KS86.fits')
    pn.atomicData.setDataFile('TEST.fits', 'O3', 'atom') # but the previous way 
to name the files is preferred
    pn.atomicData.setDataFile('o_iii_atom.chianti')

Parameters:
    - data_file    atomic data file. 
    - [atom]         selected atom
    - [data_type]    'atom', 'coll', 'rec'
    If atom and data_type not set, file format is assumed to be e.g. o_iii_coll_REF.fits
def setDataFileDict (   self,
  data_dict = None 
)
Use a dictionary for the atomic data (either predefined [string] or custom [dictionary]).

Parameters:
   - data_dict    name of the dictionary 

Member Data Documentation

calling
Chianti_path
ChiantiIONS
gsconf
log_
predefined