rotate

sknano.core.math.rotate(obj, angle=None, axis=None, anchor_point=None, rot_point=None, from_vector=None, to_vector=None, degrees=False, transform_matrix=None, verbose=False, **kwargs)[source] [edit on github][source]

Rotate object.

New in version 0.3.0.

Parameters:
  • obj (array_like) –
  • angle (float, optional) – Rotation angle in radians unless degrees is True.
  • axis ({array_like, str, Vector}) – Rotation axis.
  • anchor_point ({array_like, Point}) –
  • rot_point (Point, optional) –
  • to_vector (from_vector,) –
  • degrees (bool, optional) –
  • transform_matrix (array_like, optional) –
Returns:

rotated object

Return type:

array_like