astro query:docs

- Index
- Modules

### Navigation

- next »
- « previous |
- astroquery v0.4.11 »
- VizieR Queries (`astroquery.vizier`) »
- VizierClass

# VizierClass

class astroquery.vizier.VizierClass(*, columns=['*'], column_filters={}, catalog=None, keywords=None, ucd='', timeout=60, vizier_server='vizier.cds.unistra.fr', row_limit=50)

  Bases: `BaseQuery`

  Parameters:
    columns list

      List of strings

    column_filters dict
    catalog str or None
    keywords str or None
    ucd string

      “Unified Content Description” column descriptions. Specifying these will select only catalogs that have columns matching the column descriptions defined on the Vizier web pages. See https://vizier.cds.unistra.fr/vizier/vizHelp/1.htx#ucd and https://vizier.cds.unistra.fr/vizier/doc/UCD/

    vizier_server string

      Name of the VizieR mirror to use. (This parameter’s default is set from a configuration object.)

    timeout number

      timeout for connecting to server (This parameter’s default is set from a configuration object.)

    row_limit int

      Maximum number of rows that will be fetched from the result (set to -1 for unlimited). (This parameter’s default is set from a configuration object.)

  Attributes Summary

  `catalog` | The default catalog to search.
  `column_filters` | Filters to run on the individual columns.
  `columns` | Columns to include.
  `keywords` | The set of keywords to filter the Vizier search
  `ucd` | UCD criteria: see https://vizier.cds.unistra.fr/vizier/vizHelp/1.htx#ucd
  `valid_keywords` |

  Methods Summary

  `find_catalogs`(keywords, *[, ...]) | Search Vizier for catalogs based on a set of keywords, e.g. author name.
  `get_catalog_metadata`(*[, catalog, ...]) | Get a VizieR's catalog metadata.
  `get_catalogs`(*args, **kwargs) | Queries the service and returns a table object.
  `get_catalogs_async`(catalog, *[, verbose, ...]) | Query the Vizier service for a specific catalog
  `query_constraints`(*args, **kwargs) | Queries the service and returns a table object.
  `query_constraints_async`(*[, catalog, ...]) | Send a query to Vizier in which you specify constraints with keyword/value pairs.
  `query_object`(*args, **kwargs) | Queries the service and returns a table object.
  `query_object_async`(object_name, *[, ...]) | Serves the same purpose as `query_object` but only returns the HTTP response rather than the parsed result.
  `query_region`(*args, **kwargs) | Queries the service and returns a table object.
  `query_region_async`(coordinates, *[, radius, ...]) | Serves the same purpose as `query_region` but only returns the HTTP response rather than the parsed result.

  Attributes Documentation

  catalog

    The default catalog to search. If left empty, will search all catalogs.

  column_filters

    Filters to run on the individual columns. See the Vizier website for details.

  columns

    Columns to include. The special keyword ‘all’ will return ALL columns from ALL retrieved tables.

  keywords

    The set of keywords to filter the Vizier search

  ucd

    UCD criteria: see https://vizier.cds.unistra.fr/vizier/vizHelp/1.htx#ucd

    Examples

        >>> Vizier.ucd = '(spect.dopplerVeloc*|phys.veloc*)'

  valid_keywords

  Methods Documentation

  find_catalogs(keywords, *, include_obsolete=False, verbose=False, max_catalogs=None, return_type='votable')

    Search Vizier for catalogs based on a set of keywords, e.g. author name

    Parameters:
      keywords list or string

        List of keywords, or space-separated set of keywords. From Vizier: “names or words of title of catalog. The words are and’ed, i.e. only the catalogues characterized by all the words are selected.”

      include_obsolete bool, optional

        If set to True, catalogs marked obsolete will also be returned.

      max_catalogs int or None

        The maximum number of catalogs to return. If `None`, all catalogs will be returned.

    Returns:
      resource_dict dict

        Dictionary of the “Resource” name and the VOTable resource object. “Resources” are generally publications; one publication may contain many tables.

    Examples

        >>> from astroquery.vizier import Vizier
        >>> catalog_list = Vizier.find_catalogs('Mars')
        >>> for k, v in catalog_list.items():
        ...     print(k, ":", v.description)
        J/A+A/572/A104 : Astrometric obs. of Phobos and Deimos in 1971 (Robert+, 2014)
        J/A+A/488/361 : Mars Express astrometric observations of Phobos (Willner+, 2008)
        J/A+A/603/A55 : WISE/NEOWISE Mars-crossing asteroids (Ali-Lagoa+, 2017)
        J/A+A/545/A144 : Astrometric observations of Deimos (Pasewaldt+, 2012)
        ...

  get_catalog_metadata(*, catalog=None, get_query_payload=False)

    Get a VizieR’s catalog metadata.

    Parameters:
      catalog str, optional

        The catalog identifier. It usually looks like ‘III/55’ for big surveys or ‘J/ApJ/811/67’ for catalogs linked to a published paper. When this parameter is not provided, the function looks for the metadata of the catalog property of the Vizier class instance (`catalog`).

      get_query_payload bool, optional

        When True, returns the dict of HTTP request parameters. This does not execute the search for metadata.

    Returns:
      `Table`

        A table with the following columns: - title - authors - abstract (the abstract of the article, modified to explain the data more specifically) - origin_article (the bibcode of the associated article) - webpage (a link to VizieR, contains more information about the catalog) - created (date of creation of the catalog in VizieR) - updated (date of the last modification applied to the entry, this is often metadata, with no appearance in the history tap on the webpage but sometimes also data erratum, which will appear in the history tab) - waveband - doi (the catalog doi when it exists)

    Examples

        >>> from astroquery.vizier import Vizier
        >>> Vizier(catalog="I/324").get_catalog_metadata()
        <Table length=1>
                       title                        authors         ... waveband  doi
                       object                        object         ...  object  object
        ----------------------------------- ----------------------- ... -------- ------
        The Initial Gaia Source List (IGSL) Smart R.L.; Nicastro L. ...              --

        >>> from astroquery.vizier import Vizier
        >>> Vizier.get_catalog_metadata(catalog="J/ApJS/173/185")
        <Table length=1>
                          title                    ...              doi
                          object                   ...              object
        ------------------------------------------ ... --------------------------------
        GALEX ultraviolet atlas of nearby galaxies ... doi:10.26093/cds/vizier.21730185

  get_catalogs(*args, **kwargs)

    Queries the service and returns a table object.

    Query the Vizier service for a specific catalog

    Parameters:
      catalog str, Resource, or list, optional

        The catalog(s) that will be retrieved

    Returns:
      table A `Table` object.
  get_catalogs_async(catalog, *, verbose=False, return_type='votable', get_query_payload=False)

    Query the Vizier service for a specific catalog

    Parameters:
      catalog str, Resource, or list, optional

        The catalog(s) that will be retrieved

    Returns:
      response `Response`

        Returned if asynchronous method used

  query_constraints(*args, **kwargs)

    Queries the service and returns a table object.

    Send a query to Vizier in which you specify constraints with keyword/value pairs.

    See the vizier constraints page for details.

    Parameters:
      catalog str or list, optional

        The catalog(s) which must be searched for this identifier. If not specified, all matching catalogs will be searched.

      kwargs dict

        Any key/value pairs besides “catalog” will be parsed as additional column filters.

      cache bool

        Defaults to True. If set overrides global caching behavior. See caching documentation.

    Returns:
      table A `Table` object.

    Examples

        >>> from astroquery.vizier import Vizier
        >>> # note that glon/glat constraints here *must* be floats
        >>> result = Vizier(row_limit=3).query_constraints(catalog='J/ApJ/723/492/table1',
        ...                                   GLON='>49.0 & <51.0', GLAT='<0.0')
        >>> result[result.keys()[0]].pprint()
            GRSMC      GLON   GLAT   VLSR   DelV  ... alpha  Note RD09 _RA.icrs _DE.icrs
                       deg    deg   km / s km / s ...                    deg      deg
        ------------- ------ ------ ------ ------ ... ------ ---- ---- -------- --------
        G049.49-00.41  49.49  -0.41  56.90   9.12 ...   0.73    i RD09 290.9536  14.4992
        G049.39-00.26  49.39  -0.26  50.94   3.51 ...   0.16    i RD09 290.7682  14.4819
        G049.44-00.06  49.44  -0.06  62.00   3.67 ...   0.17    i RD09 290.6104  14.6203

  query_constraints_async(*, catalog=None, return_type='votable', cache=True, get_query_payload=False, **kwargs)

    Send a query to Vizier in which you specify constraints with keyword/value pairs.

    See the vizier constraints page for details.

    Parameters:
      catalog str or list, optional

        The catalog(s) which must be searched for this identifier. If not specified, all matching catalogs will be searched.

      kwargs dict

        Any key/value pairs besides “catalog” will be parsed as additional column filters.

      cache bool

        Defaults to True. If set overrides global caching behavior. See caching documentation.

    Returns:
      response `requests.Response`

        The response of the HTTP request.

    Examples

        >>> from astroquery.vizier import Vizier
        >>> # note that glon/glat constraints here *must* be floats
        >>> result = Vizier(row_limit=3).query_constraints(catalog='J/ApJ/723/492/table1',
        ...                                   GLON='>49.0 & <51.0', GLAT='<0.0')
        >>> result[result.keys()[0]].pprint()
            GRSMC      GLON   GLAT   VLSR   DelV  ... alpha  Note RD09 _RA.icrs _DE.icrs
                       deg    deg   km / s km / s ...                    deg      deg
        ------------- ------ ------ ------ ------ ... ------ ---- ---- -------- --------
        G049.49-00.41  49.49  -0.41  56.90   9.12 ...   0.73    i RD09 290.9536  14.4992
        G049.39-00.26  49.39  -0.26  50.94   3.51 ...   0.16    i RD09 290.7682  14.4819
        G049.44-00.06  49.44  -0.06  62.00   3.67 ...   0.17    i RD09 290.6104  14.6203

  query_object(*args, **kwargs)

    Queries the service and returns a table object.

    Serves the same purpose as `query_object` but only returns the HTTP response rather than the parsed result.

    Parameters:
      object_name str

        The name of the identifier.

      catalog str or list, optional

        The catalog(s) which must be searched for this identifier. If not specified, all matching catalogs will be searched.

      radius `Quantity` or None

        A degree-equivalent radius (optional).

      coordinate_system str or None

        If the object name is given as a coordinate, you should use `query_region`, but you can specify a coordinate frame here instead (today, J2000, B1975, B1950, B1900, B1875, B1855, Galactic, Supergal., Ecl.J2000, )

      cache bool

        Defaults to True. If set overrides global caching behavior. See caching documentation.

    Returns:
      table A `Table` object.
  query_object_async(object_name, *, catalog=None, radius=None, coordinate_frame=None, get_query_payload=False, return_type='votable', cache=True)

    Serves the same purpose as `query_object` but only returns the HTTP response rather than the parsed result.

    Parameters:
      object_name str

        The name of the identifier.

      catalog str or list, optional

        The catalog(s) which must be searched for this identifier. If not specified, all matching catalogs will be searched.

      radius `Quantity` or None

        A degree-equivalent radius (optional).

      coordinate_system str or None

        If the object name is given as a coordinate, you should use `query_region`, but you can specify a coordinate frame here instead (today, J2000, B1975, B1950, B1900, B1875, B1855, Galactic, Supergal., Ecl.J2000, )

      cache bool

        Defaults to True. If set overrides global caching behavior. See caching documentation.

    Returns:
      response `Response`

        The response of the HTTP request.

  query_region(*args, **kwargs)

    Queries the service and returns a table object.

    Serves the same purpose as `query_region` but only returns the HTTP response rather than the parsed result.

    At least one of `radius` or `width` must be specified.

    Parameters:
      coordinates str, `astropy.coordinates` object, or `Table`

        The target around which to search. It may be specified as a string in which case it is resolved using online services or as the appropriate `astropy.coordinates` object. ICRS coordinates may also be entered as a string. If a table is used, each of its rows will be queried, as long as it contains two columns named `_RAJ2000` and `_DEJ2000` with proper angular units.

      radius convertible to `Angle`

        The radius of the circular region to query.

      inner_radius convertible to `Angle`

        When set in addition to `radius`, the queried region becomes annular, with outer radius `radius` and inner radius `inner_radius`.

      width convertible to `Angle`

        The width of the square region to query.

      height convertible to `Angle`

        When set in addition to `width`, the queried region becomes rectangular, with the specified `width` and `height`.

      catalog str or list, optional

        The catalog(s) which must be searched for this identifier. If not specified, all matching catalogs will be searched.

      column_filters: dict, optional

        Constraints on columns of the result. The dictionary contains the column name as keys, and the constraints as values.

      frame str, optional

        The frame to use for the request. It should be ‘fk5’, ‘icrs’, or ‘galactic’. This choice influences the the orientation of box requests.

      cache bool

        Defaults to True. If set overrides global caching behavior. See caching documentation.

    Returns:
      table A `Table` object.
  query_region_async(coordinates, *, radius=None, inner_radius=None, width=None, height=None, catalog=None, get_query_payload=False, cache=True, return_type='votable', column_filters={}, frame='fk5')

    Serves the same purpose as `query_region` but only returns the HTTP response rather than the parsed result.

    At least one of `radius` or `width` must be specified.

    Parameters:
      coordinates str, `astropy.coordinates` object, or `Table`

        The target around which to search. It may be specified as a string in which case it is resolved using online services or as the appropriate `astropy.coordinates` object. ICRS coordinates may also be entered as a string. If a table is used, each of its rows will be queried, as long as it contains two columns named `_RAJ2000` and `_DEJ2000` with proper angular units.

      radius convertible to `Angle`

        The radius of the circular region to query.

      inner_radius convertible to `Angle`

        When set in addition to `radius`, the queried region becomes annular, with outer radius `radius` and inner radius `inner_radius`.

      width convertible to `Angle`

        The width of the square region to query.

      height convertible to `Angle`

        When set in addition to `width`, the queried region becomes rectangular, with the specified `width` and `height`.

      catalog str or list, optional

        The catalog(s) which must be searched for this identifier. If not specified, all matching catalogs will be searched.

      column_filters: dict, optional

        Constraints on columns of the result. The dictionary contains the column name as keys, and the constraints as values.

      frame str, optional

        The frame to use for the request. It should be ‘fk5’, ‘icrs’, or ‘galactic’. This choice influences the the orientation of box requests.

      cache bool

        Defaults to True. If set overrides global caching behavior. See caching documentation.

    Returns:
      response `requests.Response`

        The response of the HTTP request.