NistClass

class astroquery.nist.NistClass[source]

Bases: BaseQuery

Attributes Summary

TIMEOUT

URL

energy_level_code

order_out_code

unit_code

wavelength_unit_code

Methods Summary

query(*args, **kwargs)

Queries the service and returns a table object.

query_async(minwav, maxwav, *[, linename, ...])

Serves the same purpose as query but returns the raw HTTP response rather than a Table object.

Attributes Documentation

TIMEOUT = 30
URL = 'http://physics.nist.gov/cgi-bin/ASD/lines1.pl'
energy_level_code = {'EV': 1, 'R': 2, 'Rydberg': 2, 'cm': 0, 'cm-1': 0, 'eV': 1, 'electronvolt': 1, 'ev': 1, 'invcm': 0, 'rydberg': 2}
order_out_code = {'multiplet': 1, 'wavelength': 0}
unit_code = {'Angstrom': 0, 'nm': 1, 'um': 2}
wavelength_unit_code = {'vac+air': 4, 'vacuum': 3}

Methods Documentation

query(*args, **kwargs)

Queries the service and returns a table object.

Serves the same purpose as query but returns the raw HTTP response rather than a Table object.

Parameters:
minwavastropy.units.Quantity object

The lower wavelength for the spectrum in appropriate units.

maxwavastropy.units.Quantity object

The upper wavelength for the spectrum in appropriate units.

linenamestr or iterable of str, optional

The spectrum/spectra to fetch. Defaults to “H I”

energy_level_unitstr, optional

The energy level units must be one of the following: ‘R’, ‘Rydberg’, ‘rydberg’, ‘cm’, ‘cm-1’, ‘EV’, ‘eV’, ‘electronvolt’, ‘ev’, ‘invcm’ Defaults to ‘eV’.

output_orderstr, optional

Decide ordering of output. Must be one of following: [‘wavelength’, ‘multiplet’]. Defaults to ‘wavelength’.

wavelength_typestr, optional

Must be one of ‘vacuum’ or ‘vac+air’. Defaults to ‘vacuum’.

get_query_payloadbool, optional

If true then returns the dictionary of query parameters, posted to remote server. Defaults to False.

Returns:
tableA Table object.
query_async(minwav, maxwav, *, linename='H I', energy_level_unit='eV', output_order='wavelength', wavelength_type='vacuum', get_query_payload=False)[source]

Serves the same purpose as query but returns the raw HTTP response rather than a Table object.

Parameters:
minwavastropy.units.Quantity object

The lower wavelength for the spectrum in appropriate units.

maxwavastropy.units.Quantity object

The upper wavelength for the spectrum in appropriate units.

linenamestr or iterable of str, optional

The spectrum/spectra to fetch. Defaults to “H I”

energy_level_unitstr, optional

The energy level units must be one of the following: ‘R’, ‘Rydberg’, ‘rydberg’, ‘cm’, ‘cm-1’, ‘EV’, ‘eV’, ‘electronvolt’, ‘ev’, ‘invcm’ Defaults to ‘eV’.

output_orderstr, optional

Decide ordering of output. Must be one of following: [‘wavelength’, ‘multiplet’]. Defaults to ‘wavelength’.

wavelength_typestr, optional

Must be one of ‘vacuum’ or ‘vac+air’. Defaults to ‘vacuum’.

get_query_payloadbool, optional

If true then returns the dictionary of query parameters, posted to remote server. Defaults to False.

Returns:
responserequests.Response object

The response of the HTTP request.