Flag

From PyMOLWiki
Revision as of 14:32, 17 November 2009 by Inchoate (talk | contribs)
Jump to navigation Jump to search

Flag is a command to set or clear flags on atom sets. A flag is just some atom-specific property. A flag is either on or off for a residue. Possible flags are:

  • Flags 0-7 are reserved for molecular modeling

focus = 0

Atoms of Interest (i.e. a ligand in an active site)

free = 1

Free Atoms (free to move subject to a force-field)

restrain = 2

Restrained Atoms (typically harmonically constrained)

fix = 3

Fixed Atoms (no movement allowed)

exclude = 4

Atoms which should not be part of any simulation
  • Flags 8-15 are free for end users to manipulate
  • Flags 16-23 are reserved for external GUIs and linked applications
  • Flags 24-30 are reserved for PyMOL internal usage

exfoliate = 24

Remove surface from atoms when surfacing

ignore=25

Ignore atoms altogether when surfacing

no_smooth = 26

Do not smooth atom position
  • Flag 31 is reserved for coverage tracking when assigning parameters, etc.

If the 'auto_indicate_flags' setting is true, then PyMOL will automatically create a selection called "indicate" which contains all atoms with that flag after applying the command.

PYMOL API

 
cmd.flag(int flag, string selection, string action="reset", int indicate=0)

Examples

# get the area of a protein-ligand complex
get_area my_complex
# ignore the ligands when doing surface area
flag ignore, organic
# compare the surface area now
get_area my_complex

# in sculpting, ensure the newMethyl group just added
# doesn't move about
flag fix, newMethyl