stko.MDAnalysis
- class stko.MDAnalysis[source]
Bases:
objectConverter for
stk.Moleculeto and from MDAnalysis.- Raises:
WrapperNotInstalledError – if MDAnalysis not installed.
Examples
An stk molecule can be converted into an MDAnalysis Universe.
import stk import stko import numpy as np stkmol = stk.BuildingBlock('NCCNCCN').with_centroid( position=np.array((10, 10, 10)) ) universe = stko.MDAnalysis().get_universe(stkmol) # Can now use mdanalysis methods and analysis. radius_gyration = universe.atoms.radius_of_gyration() b_sphere = universe.atoms.bsphere() # These should be similar. universe_com = universe.atoms.center_of_mass() stk_centroid = stkmol.get_centroid()
Methods
Get an MDAnalysis object.