In [1]:
# imports
from pkg_resources import resource_filename
from astropy.table import Table
In [10]:
tspec_file = resource_filename('arclines', 'data/NIST/tspec_OH_skyline.ascii')
In [11]:
tspec = Table.read(tspec_file, format='ascii')
tspec[0:5]
Out[11]:
In [12]:
oh_lines = tspec.copy()
In [13]:
oh_lines['ion'] = 'OH'
oh_lines['NIST'] = 1
oh_lines['Instr'] = 32
oh_lines['amplitude'] = 10000. # make believe
oh_lines['Source'] = 'tspec_PYPIT.json'
In [14]:
oh_line_file = resource_filename('arclines', 'data/lists/OH_lines.dat')
In [15]:
oh_lines.write(oh_line_file, format='ascii.fixed_width')
In [2]:
nirspec_file = resource_filename('arclines', 'data/misc/nirspec_OH_R24000_vacuum.ascii')
In [4]:
nirspec = Table.read(nirspec_file, format='ascii')
In [5]:
nirspec[0:5]
Out[5]:
In [7]:
oh_lines = Table()
oh_lines['wave'] = nirspec['Wavelength']
oh_lines['amplitude'] = nirspec['Relative_Strength']
oh_lines['ion'] = 'OH'
oh_lines['NIST'] = 0
oh_lines['Instr'] = 32
oh_lines['Source'] = 'nirspec_OH_R24000_vacuum.ascii'
In [12]:
outfile = resource_filename('arclines', 'data/lists/OH_R24000_lines.dat')
In [13]:
oh_lines.write(outfile, format='ascii.fixed_width')
In [ ]: