Path C - Module 31: Proximity & Neighborhoods#

A drug doesn’t bind to an atom, it binds to a Pocket. In this module, you will learn to identify all the residues that wrap around your inhibitor using MolSysMT’s proximity engine.

import molsysmt as msm

molsys = msm.convert('pdb:6LU7', to_form='molsysmt.MolSys')

# Find all protein residues within 0.4 nm of the inhibitor
pocket = msm.get_neighbors(molsys, selection='molecule_type=="small molecule"', 
                           selection_2='molecule_type=="protein"', 
                           threshold='0.4 nm', element='group')

print(f"The binding pocket contains {len(pocket[0])} residues.")
msm.info(molsys, element='group', selection=pocket[0])