spacer link to MAST page spacer logo image spacer
 
link to STScI page


STScI's Internet connections will be UNAVAILABLE Saturday, 28 October 2017 from 7:00 AM - 1:00 PM. STScI web servers, SSH and similar services will be unreachable from the Internet.

MAST HLSP Spectral Line List Data Delivery Standards

Summer 2013

This page describes spectral line list data standards for HLSP deliveries, in FITS format Also please read the general HLSP guidelines page. Under some circumstances we will accept line lists in ASCII format; the requirements for this format are the same as for FITS with respect to header keywords (the metadata description of the data). FITS keywords fall into three categories: required, recommended and optional. more | less

MAST has put together the following information because it is essential for data deliveries. If the archive cannot extract the information they need from dataset headers, MAST will attempt to calculate it based on original exposures when possible. If MAST is not able to extract or calculate what it needs based on the delivered dataset headers, then some of the data will not be searchable and will not be displayed across multi-mission search results.

[Overview]   [General Header Information]   [FITS File Formats]   [FITS Standards]   [ASCII Standards]  

[Composite Dataset Traceability]   [Keyword Nomenclature]   [Units]   [Required Keywords]  

[Recommended Keywords]  [Optional Keywords]  [Header and Catalog Examples

Overview

Spectral line lists should be related to MAST data in order to be considered for ingestion as High Level Science Products (HLSP). Line lists should be based on observations (e.g. object or star) and provide wavelength and line ID information at a minimum. If you have line lists based on theoretical data, please also review our models/simulations HLSP guidelines.

General Header Information

MAST requires that FITS headers contain the following information (see Required keywords below):
  • Relevant ID information (object name, program ID, proposal ID, PI name, etc) if appropriate
  • Time coverage (observation start and duration) if appropriate
  • List of exposures (origin of composite data, only required for MAST Missions) if applicable
  • Wavelength coverage

FITS File Formats

The preferred spectral line list delivery format is FITS, but ASCII is also accepted. For tabular line list data in either FITS or ASCII format, a position (wavelength or frequency or wave number) and a line identifier column are required per spectral line (row). Examples are available below. Tabular data can be specified in at least 2 different ways within a FITS file: more | less

The following list enumerates what MAST will accept in order of preference; the links provided show the mandatory keys for that extension based on the FITS Standard v3.0 (Pence et al. 2010) paper:

  1. FITS Binary Table Extension - rows and columns of data in binary representation
  2. FITS ASCII Table Extension - rows and columns of data in ASCII character format

The FITS paper also provides a summary of the mandatory keywords for the above file types.

Expand for non-FITS (ASCII, CSV) details | Retract/Close details

Another option is to use non-FITS, ASCII tables to store line lists, which are also accepted by MAST. This format equates to the FITS Binary or ASCII Table Extension formats, but in straight ASCII files. More information is provided below.

Lastly, we will also accept CSV format, where the first line is always the list of column names, or otherwise listed in documentation (README).

FITS Standards

The above requirements translate into FITS header keywords below. These keywords and files themselves must abide by the FITS standard, and therefore cannot have errors when being checked by tools like 'fverify' or 'fitsverify'. more | less

For multi-extension FITS files (i.e. FITS Tabular data), please note that many of the keywords cannot be in the 0th extension or HDU, they need to be within the corresponding extension(s) which contain the data.

ASCII Table Standards

ASCII table deliveries are accepted as long as the data are well-defined and documented. Header keywords must be provided at the top of the ASCII file or as an associated data pair (one file contains the header information and the other contains the data themselves). Please abide by the FITS keyword naming scheme as described below; all required keywords must be present.

Expand for ASCII formatting and header details | Retract/Close details

The data format (columns) must be documented within the file itself and/or the supporting README file. For tabular, line list data in either FITS or ASCII format, a position (wavelength or frequency or wave number) and a line identifier column are required per spectral line (row). Units must be defined as header keywords and/or in the README file. All columns and rows must contain data values; blanks are not allowed. For blank values, please use value 'NaN' for numeric values or 'NULL' for strings in the ASCII file, but not both within the same column. Within a data line (row), fields should be separated by tabs, commas or the pipe ("|") character. We highly discourage the use of white space to separate fields if your data contains strings. If you must use spaces between fields, please quote your string values and provide information on how to read your data.

Specification of keywords and description of the column names in the ASCII file should be done as follows:

  • Use the '#' symbol to precede all keyword text lines (non-data text lines)
  • The next 8 characters are used for FITS keyword name; buffer the 8-chars name with spaces (see "NAXIS" keyword in example below)
  • The 9th character is an equal sign '=' followed by a at least a single space
  • The keyword value can be a number or string; strings must be in single quotes
  • Keyword comments are written after a "/" symbol
  • The FITS 80-character line length limit applies here: no more than 79 characters in total can be used on any given line of text; the 80th char is the end of line/return char
  • The FITS "COMMENT = " keyword should be used to describe any additional information
  • The "COMMENT = " keyword value is always a string within single quotes

The following is an ASCII spectra header example of keyword, value pairs, including the 4 data column descriptions for wavelength, flux, error, and data quality. Note that these map directly onto FITS header keywords so that MAST can build FITS files from ASCII tabular spectra deliveries.

                                                           
#TELESCOP= 'HST'                  / Observatory name.
#INSTRUME= 'STIS'                 / Instrument name.
#DATE-OBS= '2013-08-13T13:01:01'  / Date of observation start.
#EXPTIME = 444                    / Effective exposure time (sec).
#EXPSTART= 56518.042373           / Start time of observation (MJD).
#EXPEND  = 56518.048108           / End time of observation (MJD).
#RADESYS = 'FK5'                  / Astrometric reference system.
#RA_TARG = 176.42621755           / Right ascension of object (deg).
#DEC_TARG= 2.82148162             / Declination of object (deg).
#WAVEMIN = 4862.72                / Minimum wavelength in spectrum.
#WAVEMAX = 6564.60                / Maximum wavelength in spectrum.
#TARGNAME= 'HD102195'             / Target name.
#EQUINOX = 2000.                  / Equinox of the coordinates.
#AIRORVAC= 'VAC'		          / Wavelengths in AIR or VACUUM?
#BITPIX  = 8                      / 8-bit bytes.
#NAXIS   = 2                      / 2-dimensional table.
#NAXIS1  = 17                     / Width of table in bytes.
#NAXIS2  = 6                      / Number of rows in table.
#PCOUNT  = 0                      / Size of spectral data area.
#GCOUNT  = 1                      / One data group (required keyword).
#TFIELDS = 4                      / Number of fields in each row.
#TTYPE1  = 'WAVE'                 / Label for field 1.
#TFORM1  = '1E'                   / Data format of field: 4-byte REAL
#TUNIT1  = 'ANGSTROMS'            / Physical unit of field.
#TTYPE2  = 'NAME'                 / Label for field 2.
#TFORM2  = '7A'                   / Data format of field: 1-byte CHAR
#TTYPE3  = 'EW'                   / Label for field 3.
#TFORM3  = '1E'                   / Data format of field: 4-byte REAL
#TUNIT3  = 'ANGSTROMS'            / Physical unit of field.
#TTYPE4  = 'LIMIT-FLAG'           / Label for field 4.
#TFORM4  = '1E'                   / Data format of field: 2-byte INT
#
#COMMENT = 'Delivered to MAST from the [fill in name] HLSP project'
#END                                                                             

Composite Dataset Traceability

Composite data deliveries of MAST Missions are required to contain a list of the original datasets from which the combined dataset was made. more | less

Composite data are defined as products which were constructed from other datasets.

The list of original datasets from which the dataset was made can be in the README file or provided within the dataset. Please discuss these options with MAST prior to delivery.

An example composite map from the PHAT HLSP project can be viewed within the PHAT catalog header where the "IM1*" through "IM5*" header keywords denote the observational details regarding the original 5 datasets that were used to create the catalog.

Header Keyword Nomenclature

In order to capture some keywords which is a composite, that keyword can contain the value of "MULTI", followed by a list of N similar keywords which encompass all the values needed to explain the composite data using a series of related keywords. more | less

For example, a line list can be built from a single observation with FITS keyword 'INSTRUME' = "COS". For a composite line list made extracting line information from several sources, say COS and STIS data, the keys would be as follows:

  • INSTRUME = "MULTI"
  • INSTRU01 = "COS"
  • INSTRU02 = "STIS"

To designate multiple keywords, we denote this as [nn].

Keyword Value Units

Some keywords have standard units and do not need to be explicitly specified in the headers. In cases where you need to specify units for header keywords, this can be done in one of two ways: more | less

  1. KEYWORD + KEYWORD_UNIT pair
  2. You can specify the keyword units using a second, similar keyword where the keyword name contains the string "_UNIT" or "UNIT". Please remember to stay within the FITS 8-character keyword name limit. E.g.:

    WAVECENT = 1688 / central wavelength
    WAVEUNIT = angstrom / central wavelength units

  3. KEYWORD = value / [unit] in brackets within the FITS comment
  4. Comments can contain the keyword unit within brackets; this should be the first text following the standard fits comment delimiter "/", the single slash. Please remember to stay within the FITS 80-character line length limit, which includes the comments. E.g.:

    RA_TARG = 2.0952854139 / [deg] right ascension of target

Back to top


REQUIRED FITS HEADER KEYWORDS


KeywordDescription
  
             // For Tabular FITS Data: BINARY/ ASCII TABLE EXTENSION KEYWORDS
SIMPLE T / FITS standard
XTENSION Type of extension: FITS BINTABLE or FITS ASCII table
EXTNAME Extension name (single word)
(EXTNO) Extension number - recommended keyword
BITPIX number of bits that represent a data value
NAXIS 2 / denoting that the included data array is two-dimensional: rows and columns.
NAXIS1 the number of 8-bit bytes in each row of the table
NAXIS2 number of rows in the table
PCOUNT Random parameter count
GCOUNT Group count
TFIELDS Number of columns
TBCOL[n] [FITS ASCII table ONLY] Integer specifying the column in which field n starts (starting at 1).
TFORM[n] [FITS BINARY table ONLY] Format of column (valid data types)
TTYPE[n] Name of column (e.g. WAVE, FLUX, ERROR, DQ)
TUNIT[n] Column units (e.g. Angstroms, erg/s/cm^2/A, unitless)

Back to top


RECOMMENDED FITS HEADER KEYWORDS


KeywordDescription
  
  
             // DATE AND TIME KEYWORDS
DATE-OBS date and time of observation start in the ISO standard 8601 format: YYYY-MM-DDThh:mm:ss.sss; start of first observation if composite
(DATE-OBS) Alternative, accepted date format (yyyy-mm-dd); must be paired with TIME-OBS
(TIME-OBS) Alternative, accepted time format (hh:mm:ss); must be paired with DATE-OBS (yyyy-mm-dd)
EXPTIME effective exposure time (seconds) for single exposure, or "1" for composite (which are typically in units of counts/second, see EXP* keywords below).
EXPSTART start time of observation, or first exposure if composite [MJD]
EXPEND end time of observation, or last exposure if composite [MJD]
  
             // PROPOSAL KEYWORDS
PROPOSID Proposal ID (when available)
HLSPLEAD Full name of the lead of HLSP project (Firstname M. Lastname)
PR_INV_L Last name of principal investigator
PR_INV_F First name of principal investigator
PR_INV_M Middle name or initial of principal investigator

Back to top


OPTIONAL FITS HEADER KEYWORDS


KeywordDescription
  
             // DATA DESCRIPTION KEYWORDS
TELESCOP observatory/facility (e.g. HST, IUE, ISO, VLT, NIST) [Expand TELESCOP values List | Retract/Close List]

INSTRUME single instrument alone, or instrument/detector names, or instrument/detector-subdetector names (e.g. "WFPC2" or "ACS/WFC" or "ISOCAM" or "STIS/FUV-MAMA") or "MULTI" for composite [View Current List]
INSTRU[nn] if INSTRUME="MULTI", then an element from allowed values of INSTRUME [View Current List]
  
TARGNAMEtarget name (according to raw data or catalog)
RA_TARGright ascension of the target [deg] (J2000)
DEC_TARGdeclination of the target [deg] (J2000)
EPOCH Epoch of the observation (considered as deprecated; use EQUINOX when possible)
EQUINOX Equinox of celestial coord. system
FILTER filter for single exposure or "MULTI" for composite exposure [View Current List]
FILTER[nn] if FILTER="MULTI", filters list when composite exposure [View Current List]
  
HLSPNAME High Level Science Product (HLSP) project name, long form
HLSPACRN High Level Science Product (HLSP) project acronym, short form
CITATION citation reference of this project, for publications (else in HLSP README file)
DETECTOR detector of the instrument (same order as INTRUME) or "MULTI" for composite exposure
DETECT[nn] list of detectors of the instrument of composite exposure
APERTURE for HST, the name of the aperture of the instrument (i.e. STIS apertures)
  
WAVEMIN minimum wavelength n'th order
WAVEMAX maximum wavelength n'th order
WAVEUNIT Unit for the MINWL, MAXWL and wavelength coordinates in the file {nm, ang, micron, mm, wavenum}
AIRORVAC are the wavelengths in air or vacuum? One of {air, vac}.
SPECRES spectral resolution (delta lambda) at a given wavelength provided by WAVERES.
WAVERES The reference wavelength of SPECRES in units of WAVEUNIT, the resolving power "R" (often misquoted as the "resolution") would then be given as WAVERES / SPECRES.
WAVECENT effective wavelength, or central wavelength
  
EXPDEFN string describing how EXPTIME was calculated, i.e. 'MEAN', when composite exposure
EXPMIN if EXPDEFN='MIN', numerical value = minimum composite exposure
EXPMAX if EXPDEFN='MAX', numerical value = maximum composite exposure
EXPMODE if EXPDEFN='MODE',numerical value = mode of composite exposure
EXPMED if EXPDEFN='MED', numerical value = median of composite exposure
EXPMEAN if EXPDEFN='MEAN', numerical value = mean of composite exposure
EXPSUM if EXPDEFN='SUM',numerical value = sum of composite exposure

Back to top


HLSP Line List, Catalog and Spectra Header Examples

Expand for Examples | Retract/Close Examples

MAST has been ingesting and distributing HLSP data products for over 10 years. During this period, the requirements for HLSP data deliveries have expanded in order to help unify all datasets housed at MAST for ease of multi-mission searching. The example HLSP headers may not abide by all the requirements listed above because they were delivered prior to some requirements being written. Please note that MAST has only had one Spectral Line List HLSP delivery to date which is listed in the examples below; the rest of the examples are to show examples data type packaging and formatting. We encourage the data delivery teams to provide data sample so that all header and data issues can be worked out prior to the actual delivery for ingestion into the archive.

The following projects contain many examples of catalog file headers, which can be used as a guideline for your datasets:

Back to general HLSP guidelines

Back to top