ensemble2trajectoryΒΆ

Create a trajectory (.xtc) file from an ensemble of .pdb files.

FunctionsΒΆ

ensemble2traj([ensemble_dir, trajectory_dir, ...])

Create a trajectory (.xtc) file from an ensemble of .pdb files.

Module ContentsΒΆ

ensemblify.conversion.ensemble2trajectory.ensemble2traj(ensemble_dir=None, trajectory_dir=None, trajectory_id='', trajectory_size=None)ΒΆ

Create a trajectory (.xtc) file from an ensemble of .pdb files.

Additionally, one of the .pdb files used to create this trajectory is kept as a .pdb topology file. Uses GROMACS for trajectory conversion if installed, else uses MDAnalysis.

Parameters:
  • ensemble_dir (str, optional) – Path to directory where all the .pdb files are stored. Defaults to current working directory.

  • trajectory_dir (str, optional) – Path to directory where trajectory .xtc file will be created. Will be created if it does not exist. Defaults to current working directory.

  • trajectory_id (str, optional) – Prefix identifier for any created files.

  • trajectory_size (int, optional) – Number of randomly sampled .pdb files to use for trajectory creation. Defaults to all .pdb files in the ensemble directory.

Returns:

trajectory_path (str):

Path to created trajectory .xtc file.

topology_path (str):

Path to created topology .pdb file.

Return type:

tuple[str,str]