SkyCoordInfo#

class astropy.coordinates.SkyCoordInfo(bound=False)[source]#

Bases: MixinInfo

Container for meta information like name, description, format. This is required when the object is used as a mixin column within a table, but can be used as a general way to store meta information.

Attributes Summary

attrs_from_parent

unit

Methods Summary

default_format(val)

new_like(skycoords, length[, ...])

Return a new SkyCoord instance which is consistent with the input SkyCoord objects skycoords and has length rows.

Attributes Documentation

attrs_from_parent = {'unit'}#
unit#

Methods Documentation

static default_format(val)[source]#
new_like(skycoords, length, metadata_conflicts='warn', name=None)[source]#

Return a new SkyCoord instance which is consistent with the input SkyCoord objects skycoords and has length rows. Being “consistent” is defined as being able to set an item from one to each of the rest without any exception being raised.

This is intended for creating a new SkyCoord instance whose elements can be set in-place for table operations like join or vstack. This is used when a SkyCoord object is used as a mixin column in an astropy Table.

The data values are not predictable and it is expected that the consumer of the object will fill in all values.

Parameters:
skycoordslist

List of input SkyCoord objects

lengthint

Length of the output skycoord object

metadata_conflictsstr (‘warn’|’error’|’silent’)

How to handle metadata conflicts

namestr

Output name (sets output skycoord.info.name)

Returns:
skycoordSkyCoord (or subclass)

Instance of this class consistent with skycoords