A PyMOL script to highlight transmembrane segments and related structural elements on a given PDB structure. Annotations are retrieved from either PDBTM or OPM. Choosing PDBTM essentially reproduces the behaviour of the viewer on their website within PyMOL.
Note that OPM does not have explicit definitions for membrane sides. In addition there is no (accessible) distinction between interfacial, reentrant and transmembrane helices, so all are colored the same (yellow) OPM only gives a non-redundant list of subunit annotations in one file. Therefore queuing for PDB code '1xfh' will not give a hit, since the representative structure for this cluster is '2nwl' and only this one appears in the subunits file.
-
For current session only, execute in Pymol CLI:
import hlmem
-
For permanent availability and GUI:
- Start Pymol and go to Plugin -> Manage Plugins -> Install, then choose hlmem.py
- Or dedicate a local folder as additional script ressource and include it in your pymolrc, as seen here
- Pymol GUI: Plugin -> Membrane Protein Highlight
- Pymol CLI: hmem [pdbCode [,loaded,(OPM|PDBTM)],coloring]
If loaded=0 (default), the structure will be fetched before highlighting, otherwise only selections will be created. Coloring of those selection is enabled by default but can be supressed. Default highlights are from PDBTM, but OPM can be specified as well.
hmem 2nwl,0,OPM //Fetch 2nwl and highlight according to OPM
hmem 2nwl //Use already loaded 2nwl and highlight according to PDBTM
hmem 2nwl,0,PDBTM,0 //Fetch 2nwl and create selections for transmembrane segments according to PDBTM
- Offer to copy OPM annotations for redundant hits (annotations are only given for a non-redundant set of structures)