stacker.residue_movement.calc_center_3pts#
- calc_center_3pts(a, b, c)[source]#
Finds the average x, y, z position of three (x, y, z) Vectors.
Takes in three Vectors generated using the pdb.xyz method and finds their center. Works with three points that make up a triangle (like those within a 6-member ring).
- Parameters:
- aVector
x, y, z coordinates of the first point.
- bVector
x, y, z coordinates of the second point.
- cVector
x, y, z coordinates of the third point.
- Returns:
- midpointVector
One Vector with (x, y, z) coordinates at the center of the three input Vectors.
See also
Base
Python Class that represents a nucleotide base
calculate_bottaro_values_for_frame
Calculates the r, rho, and theta values as expressed in the Bottaro paper.
create_base_from_coords_list
Combines C2, C4, C6 positions with midpoint positions for a given frame
Examples
>>> import stacker as st >>> print(st.calc_center_3pts(st.Vector(0,0,0), st.Vector(1,1,1), st.Vector(2,2,2))) [ 1.0 1.0 1.0 ]