-
Notifications
You must be signed in to change notification settings - Fork 825
Closed
Labels
Description
The examples in the documentation of transforms.rotate.rotateby are not up-to-date since they call transformations.rotate instead of transforms.rotate.rotateby.
mdanalysis/package/MDAnalysis/transformations/rotate.py
Lines 41 to 70 in 3ea6e43
| def rotateby(angle, direction, point=None, ag=None, weights=None, wrap=False): | |
| ''' | |
| Rotates the trajectory by a given angle on a given axis. The axis is defined by | |
| the user, combining the direction vector and a point. This point can be the center | |
| of geometry or the center of mass of a user defined AtomGroup, or an array defining | |
| custom coordinates. | |
| Examples | |
| -------- | |
| e.g. rotate the coordinates by 90 degrees on a axis formed by the [0,0,1] vector and | |
| the center of geometry of a given AtomGroup: | |
| .. code-block:: python | |
| ts = u.trajectory.ts | |
| angle = 90 | |
| ag = u.atoms() | |
| d = [0,0,1] | |
| rotated = MDAnalysis.transformations.rotate(angle, direction=d, ag=ag)(ts) | |
| e.g. rotate the coordinates by a custom axis: | |
| .. code-block:: python | |
| ts = u.trajectory.ts | |
| angle = 90 | |
| p = [1,2,3] | |
| d = [0,0,1] | |
| rotated = MDAnalysis.transformations.rotate(angle, direction=d, point=point)(ts) |
I'll provide a quick fix.
Reactions are currently unavailable