astro py:docs

- Index
- Modules

### Navigation

- next »
- « previous |
- Astropy v0.3 »
- Astronomical Coordinate Systems (`astropy.coordinates`) »
- FunctionTransform

# FunctionTransform

class `astropy.coordinates.transformations.``FunctionTransform`(fromsys, tosys, func, copyobstime=True, priority=1, register=True)

  Bases: `astropy.coordinates.transformations.CoordinateTransform`

  A coordinate transformation defined by a function that simply accepts a coordinate object and returns the transformed coordinate object.

  Parameters:

  fromsys : class

  > The coordinate system class to start from.

  tosys : class

  > The coordinate system class to transform into.

  func : callable

  > The transformation function.

  copyobstime : bool

  > If True (default) the value of the `_obstime` attribute will be copied to the newly-produced coordinate.

  priority : number

  > The priority if this transform when finding the shortest coordinate tranform path - large numbers are lower priorities.

  register : bool

  > Determines if this transformation will be registered in the astropy master transform graph.

  Raises:

  TypeError :

  > If `func` is not callable.

  ValueError :

  > If `func` cannot accept one argument.