query

astroquery.sha.query(coord=None, ra=None, dec=None, size=None, naifid=None, pid=None, reqkey=None, dataset=2, verbosity=3, return_response=False, return_payload=False)[source]

Query the Spitzer Heritage Archive (SHA).

Four query types are valid to search by position, NAIFID, PID, and ReqKey:

position -> search a region
naifid   -> NAIF ID, which is a unique number allocated to solar
            system objects (e.g. planets, asteroids, comets,
            spacecraft) by the NAIF at JPL.
pid      -> program ID
reqkey   -> AOR ID: Astronomical Observation Request ID

For a valid query, enter only parameters related to a single query type:

position -> ra, dec, size
naifid   -> naifid
pid      -> pid
reqkey   -> reqkey
Parameters
coordastropy.coordinates.builtin_systems

Astropy coordinate object. (query_type = ‘position’)

ranumber

Right ascension in degrees, alternative to using coord. (query_type = ‘position’)

decnumber

Declination in degrees, alternative to using coord. (query_type = ‘position’)

sizenumber

Region size in degrees. (query_type = ‘position’)

naifidnumber

NAIF ID. (query_type = ‘naifid’)

pidnumber

Program ID. (query_type = ‘pid’)

reqkeynumber

Astronomical Observation Request ID. (query_type = ‘reqkey’)

datasetnumber, default 2

Data set. Valid options:

1 -> BCD data
2 -> PBCD data
verbositynumber, default 3

Verbosity level, controls the number of columns to output.

Returns
tableTable

Notes

For column descriptions, metadata, and other information visit the SHA query API help page

Examples

Position query using an astropy coordinate object

>>> import astropy.coordinates as coord
>>> import astropy.units as u
>>> from astroquery import sha
>>> pos_t = sha.query(coord=coord.SkyCoord(ra=163.6136, dec=-11.784,
... unit=(u.degree, u.degree)), size=0.5)

Position query with optional ra and dec parameters

>>> pos_t = sha.query(ra=163.6136, dec=-11.784, size=0.5)

NAIFID query

>>> nid_t = sha.query(naifid=2003226)

PID query

>>> pid_t = sha.query(pid=30080)

ReqKey query

>>> rqk_t = sha.query(reqkey=21641216)