Difference between revisions of "Spin ID strings"

From relax wiki
Jump to navigation Jump to search
Line 18: Line 18:
 
Regular expression can, in some instances, be used to select spins. For example the string
 
Regular expression can, in some instances, be used to select spins. For example the string
 
'''@H*''' will select the protons ‘H’, ‘H2’ and ‘H98’.
 
'''@H*''' will select the protons ‘H’, ‘H2’ and ‘H98’.
 +
 +
== See current spins ==
 +
  
 
== Example ==
 
== Example ==
 +
deselect.spin(spin_id=':5@N', change_all=False)

Revision as of 12:39, 28 February 2014

See manual

4.2.2 Molecule, residue, and spin containers

Structure

  1. The molecule ID token beginning with the # character,
  2. The residue ID token beginning with the : character,
  3. The atom or spin system ID token beginning with the @ character.

The full ID string specification is

#<mol name> :<res id>[, <res id>[, <res id>, ...]] @<atom id>[,<atom id>[, <atom id>, ...]]

Where the token elements are <mol name>, the name of the molecule, <res id>, the residue identifier which can be a number, name, or range of numbers,
<atom id>, the atom or spin system identifier which can be a number, name, or range of numbers.

If one of the tokens is left out then all elements will be assumed to match.
For example if the string does not contain the # character then all molecules will match the string.
If only the molecule ID component is specified, then all spins of the molecule will match.
Regular expression can, in some instances, be used to select spins. For example the string @H* will select the protons ‘H’, ‘H2’ and ‘H98’.

See current spins

Example

deselect.spin(spin_id=':5@N', change_all=False)