pylipid.func.collect_bound_poses¶
- pylipid.func.collect_bound_poses(binding_site_map, contact_residue_index, trajfile_list, topfile_list, lipid, protein_ref, lipid_ref, stride=1, nprot=1)[source]¶
Collected the bound poses from trajectories.
The bound poses of binding sites specified in the
binding_site_map
are collected from trajectories based on the contacting lipid residue index that is provided bycontact_residue_index
.In implementation, the
binding_site_map provides
a dictionary that informs of what residues constitues the selected binding sites. Thecontact_residue_index
is the lipid index generated bypylipid.api.LipidInteraction.collect_residue_contacts()
, which is a python dictionary that records, for each residue, the contacting lipid indices at each trajectory frame. The contacting lipids at each trajectory frame are calculated by merging, with duplicates removed, the contacting lipid molecules of the binding site residues. The coordinates of the contacting lipid molecules, together with the protein coordinates that the lipid poses bind are taken from the trajectories and made into a MDtraj.Trajectory object, which contains coordinates and topology information of the protein-lipid complex and the unitcell information of the simulation box at the time the poses were taken.protein_ref
andlipid_ref
are the MDtraj topology object (mdtraj.Topology) of a copy of the protein molecule and a copy of the lipid molecule respectively. These two are combined to generate the topology object for the protein-lipid complex which is required for mdtraj.Trajectory object of the bound poses.The simulation trajectories are read in this function to obtain the lipid and receptor coordinates. Therefore, the order of the
trajfile_list
andtopfile_list
and the settings ofstride
andnprot
should keep consistent with the settings that generated the contacting lipid indexcontact_residue_index
.- Parameters
binding_site_map (dict) – A python dictionary with the selected binding site IDs as its keys and the binding site residue indices as the corresponding values. {binding site ID: a list of binding site residue indices}
contact_residue_index (dict) – A python dictionary that records contacting lipid molecule indices for residues. It should has residue indices as its keys and a list of contacting lipid molecule residue indices for each of the trajectory frame as their corresponding values.
trajfile_list (list of str) – A list of trajectory files.
topfile_list (list of str) – A list of topology files.
lipid (str) – Residue name of the lipid to check.
protein_ref (mdtraj.Topology or mdtraj.Trajectory) – A MDtraj object of a copy of the protein molecule that contains topology information of the protein.
lipid_ref (mdtraj.Trajectory) – A MDtraj object of a copy of the lipid molecule that contains topology information of the lipid molecule.
stride (int,default=1) – Analyze every stride-th frame of the trajectories. Should keep consistent with the settings that generated the contacting lipid index
contact_residue_index
.nprot (int, default=1) – Number of copies of proteins in the simulation systems. Should keep consistent with the settings that generated the contacting lipid index
contact_residue_index
.
- Returns
pose_traj (dict) – A python dictionary that stores bound pose coordinates. This python dictionary has the selected binding site IDs as its keys and each corresponding value contains a mdtraj.Trajectory object that contains the bound lipid coordinates with the receptor coordinates the lipid bind to.
pose_info (dict) – A python dictionary that stores the corresponding information to the lipid poses in
pose_traj
. The pose information is a tuple of four figures, which correspond to traj_idx, protein_idx, lipid_residue_index, frame_id*traj.timestep.
See also
pylipid.func.cal_contact_residues
The function that calculates the contact residues from distance matrix
pylipid.api.LipidInteraction.collect_residue_contacts
The function that creates contact lipid index.
pylipid.api.LipidInteraction.analyze_bound_poses
The function that analyzes lipid bound poses.