fractaldna.dna_models.molecules.Guanine

class fractaldna.dna_models.molecules.Guanine(strand=-1, chain=-1, position=array([0., 0., 0.]), rotation=array([0., 0., 0.]), index=0)

Bases: Molecule

Guanine molecule

Parameters:
  • strand (int) – strand ID

  • chain (int) – Chain ID

  • position (array) – position array (3-vector)

  • rotation (array) – rotation array (euler angles)

  • index (int) – base pait index

__init__(strand=-1, chain=-1, position=array([0., 0., 0.]), rotation=array([0., 0., 0.]), index=0)

constructor

Methods

__init__([strand, chain, position, ...])

constructor

point_in_molecule(point)

Assert whether a point (x, y, z) is inside the molecule.

rotate(rotation)

Rotate molecule by [X_angle, Y_angle, Z_angle]

to_series()

Convert molecule to a pandas series

to_text([seperator])

Return a text description of the molecule Molecule.toText(seperator=" ")

translate(translation)

type translation:

array

point_in_molecule(point)

Assert whether a point (x, y, z) is inside the molecule.

Param:

point (x, y, z)

Return type:

bool

Returns:

True/False point in molecule

rotate(rotation)

Rotate molecule by [X_angle, Y_angle, Z_angle]

Parameters:

rotation (array) – Euler angles for rotation

Return type:

None

to_series()

Convert molecule to a pandas series

Return type:

Series

Returns:

Series representation of the molecule

to_text(seperator=' ')

Return a text description of the molecule Molecule.toText(seperator=” “)

Parameters:

seperator (str) – seperation character

Return type:

str

translate(translation)
Parameters:

translation (array) – Translate the molecule by (x, y, z)

Return type:

None