ICM Manual v.3.1
by Ruben Abagyan
Copyright © 2005, Molsoft LLC
Aug 8 2008

Contents
 
Introduction
Reference Guide
 ICM options
 Editing
 Graph.Controls
 Alignment Editor
 Constants
 Subsets
 Molecules
 Selections
 Regexp
 Tree cluster
 Arithmetics
 Flow control
 MolObjects
 Energy Terms
 Integers
 Reals
 Logicals
 Strings
 Preferences
 Tables
 Other
 Chemical
 Smiles
 Gui programming
 Commands
  add
  alias
  align
  Append command
  assign
  break
  build
  call
  center
  clear
  color
  Color accessibility
  Compare
  compress
  connect
  continue
  convert
  copy
  crypt
  Delete
  display
  edit
  elseif
  endfor
  endif
  endmacro
  Enumerate chiral
  Enumerate tautomer
  Enumerate library
  endwhile
  exit
  find
  fix
  for
  fork
  fprintf
  Global
  goto
  group
  Gui
  help
  history
  if
  info
  keep
  join tables
  Learn
  Link group
  Link variables
  Link alignment to 3D
  list
  List binary
  List database
  list molcart
  load
  Macro
  make
  minimize
  menu
  modify
  Modify chem
  montecarlo
  move
  pause
  plot
  Plot area
  print
  Print bar
  printf
  print image
  Query molcart
  quit
  randomize
  read
  rename
  return
  rotate
  select
  Set
  show
  sort
  split
  sprintf
  store
  ssearch
  strip
  superimpose
  Superimpose minimize
  Sys
  test
  then
  transform
  translate
  undisplay
  undisplay window
  unfix
  wait
  web
  while
  write
 Functions
 Macros
 Files
User's Guide
References
Glossary
 
Index

PrevICM Language Reference
Commands
Next

[ add | alias | align | Append command | assign | break | build | call | center | clear | color | Color accessibility | Compare | compress | connect | continue | convert | copy | crypt | Delete | display | edit | elseif | endfor | endif | endmacro | Enumerate chiral | Enumerate tautomer | Enumerate library | endwhile | exit | find | fix | for | fork | fprintf | Global | goto | group | Gui | help | history | if | info | keep | join tables | Learn | Link group | Link variables | Link alignment to 3D | list | List binary | List database | list molcart | load | Macro | make | minimize | menu | modify | Modify chem | montecarlo | move | pause | plot | Plot area | print | Print bar | printf | print image | Query molcart | quit | randomize | read | rename | return | rotate | select | Set | show | sort | split | sprintf | store | ssearch | strip | superimpose | Superimpose minimize | Sys | test | then | transform | translate | undisplay | undisplay window | unfix | wait | web | while | write ]


add


[ Add column | Add matrix | Add slide | Add table ]

A family of commands adding things. Some cammands use append syntax instead It is also used as an option equivalent to append in write command.

add one or several columns or header elements to an existing table


Single column/header addition

add column T I|R|S|P|i|r|s [name= s ] [index= i_pos] [mute]

add header T I|R|S|P|i|r|s|M|etc [name= s ] [mute]

Multiple column/header addition

add column T I|R|S|P|i|r|s I|R|S|P|i|r|s .. [name= S] [index= i_pos ] [mute]

add header T I|R|S|P|i|r|s|M|etc I|R|S|P|i|r|s|M|etc .. [name= S] [index= i_pos ] [mute]

this command adds one or several columns to an existing table in the i_pos column (in other words if you want you column to be in the 2nd position, specify 2 as an argument). The columns are append to the end of the table by default. If the table does not exist the command will create a new table.

It an integer, string, or real are specified as an argument instead of a column-array, this value is multipled to create a column of the appropriate size.

The mute option suppresses the info (equivalent to temporarily setting l_info=no ).

Examples:


add column t {1 2 3} # create a new table
add header t "A new table" name="title" # add a string to the header section
add column t {"a","b","c"} name="AA" # column AA is appended
add column t {"x","y","z"} index = 2 
# adding a chemical array
add column t Parray({"CC","CC(O)=O","CCO"} smiles) name = "mol" index = 1

# adding multiple arrays
add column t {1 2 3} {3 2 1} {"a","b","c"} Parray({"CC","CC(O)=O","CCO"} smiles) name={"A","B","C","mol"}
t
 #>T t
 #>-A-----------B-----------C-----------mol--------
    1           3           a          "CC"
    2           2           b          "CC(O)=O"
    3           1           c          "CCO"

See also: move column

Adding real arrays as matrix rows


add matrix [ M ] R

adds a matching row R to matrix M . If the matrix does not exist it is created with the default name (the name is saved in s_out ) Example:


add matrix M {1. 2.} # creates new matrix M
add matrix M {3. 3.} # adds a row
show M
 #>M M
 1. 2. 
 3. 3.

add slide to a slideshow.


add slide [i_posInCurrentSlideshow] [s_slideTitle] [comment = s_slideComment] [ display= "-option|-option" ]

adds a slide to the slideshow table. This table contains one parray, called slideshow.slides . If the slide position is not specified the slide will be added to the end. Alternatively, it will be inserted after the specified i_posInCurrentSlideshow

Normally the slide is saved with window layout, and graphical parameters. Those can be ignored if you add the display="-.." option. The options can be used either in the on mode, e.g. "-layout", or in the off mode, e.g. "+layout" (all on by default) :

  • "-layout" # ignores the window/panel layout
  • "-smooth" # ignores smooth view transitions between slides
  • "-add" # do not overwrite the previous slide views, just add to it
  • "-gf" # ignore graphical representations, inherit them
  • "-color" # ignore colors , inherit them
  • "-labeloffs" # do not display labels
  • "-viewpoint" # ignore viewpoint changes
  • "-graphopt" #
  • "-mol" # do not display the chem-table window
  • "-grob" # do not display grobs
  • "-map" # do not display maps
  • "-all" # switches off all the above properties

Example:


build string "ala ala ala"
display ribbon a_ 
display xstick a_/12,13 magenta
add slide "My View" comment = "These two residues are particularly dear to me" display="-layout"
undisplay # hide all
# wait..
display slide "My View" # bring it back

See also: display slide , Slide

Add / insert table rows. Append tables.


add T_1 [ i_RowNumber ] [ T_2 | row_selection ]
add/insert rows (or another table with the same coloumns) to table T_1 at the target row position i_RowNumber . Use 1 (one) if you need to insert the first line. If the second table or selection is not provided, the command adds an empty row. The row_selection can contain rows from the same table or from a different table with a matching column structure. In the latter case, the columns may be matched by their names regardless of column order. Default values are inserted for all absent columns. The defaults for an empty line are empty string or zero value for strings or numbers, respectively. The target position will then correspond to the index of the first inserted row.


Examples:

 
group table t {1 2 3} "a" {"b","d","e"} "b" 
show t 
 #>T t 
 #>-a-----------b---------- 
    1           b 
    2           d 
    3           e 
 
add t 1 # insert empty line before 1st  
show t 
 #>T t 
 #>-a-----------b---------- 
    0           ""  
    1           b 
    2           d 
    3           e 
 
group table t {1 2 3} "a" {"b","d","e"} "b" # recreate the table 
add t 3 t[1]  # insert a duplicate of 1st row after the 2nd  
show t
 #>T t 
 #>-a-----------b---------- 
    1           b 
    2           d 
    1           b 
    3           e 
 
group table t {1 2 3}  "a"  {"b","d","e"} "b"  # recreate the table 
group table tt {1 2 3} "c" {"b","d","e"} "b" {4 5 6} "a" # another table 
# order is diffferent, extra column present  
add t 3 tt[1:2]  # or add t 3 tt.aa<3  
show t 
 #>T t 
 #>-a-----------b---------- 
    1           b 
    2           d 
    4           b 
    5           d 
    3           e 


alias


alias abbreviation word1 word2 ...
create alias
alias delete abbreviation
delete alias
It is important that the abbreviation is not used in the ICM-shell. The same names can not be given later to ICM-shell objects.
Alias may contain arguments $0, $1, $2, etc. ICM-shell will pick space-separated words following the alias name and substitute $1, $2, etc. arguments by the specified argument. $0 stands for all the arguments after the alias name.
Examples:
 
 alias seq sequence                    # seq will invoke sequence  
 alias delete seq                      # delete alias name seq  
 alias dsb display a_//ca,c,n          # abbreviate several words to  
                                       # reduce typing efforts  
                                       # aliases with arguments  
 alias NORM ($1-Mean($1))/Rmsd($1) 
 show NORM {6,7,8,4,6,5,6,7,5,6}       # make sure there is no space 


align


[ Align res numbers | Align sequence | Align fragments | Align 3D | Align 3D heavy ]



align number: renumber residues sequentially


align number rs_residuesToBeRenumbered [ i_firstNumber ]
align number ms_chainsToBeRenumbered [ i_firstNumber ]
renumber selected residues, or residues in selected molecules or objects sequentially in all of them from starting one or the specified first number. May be useful to deal with messy numbering in some pdb-files. Example:
 
 read pdb "1crn" 
 align number a_1            # renumber all res. 1 to N 
 align number a_1/10:20 101  # just the selected residues from 101 
 align number a_1       101  # renumber all res. 101 to 100+N 

align number ms_chainsToBeRenumbered seq_master [ i_offset ] renumber the residues of the selected molecule according to seq_master master sequence which is aligned to the sequence of the selected chain. The alignment (pairwise or multiple) need to be linked to the molecule/chain and both the chain sequence and the master sequence need to be covered by the alignment. The molecular sequence can be generated with the make sequence [ ms_chainsToBeRenumbered ] command. The can be either aligned anew the the master sequence with the Align function or appended to a multiple sequence alignment using alignment projection.
This command may be useful in cases in which a structural model does not represent the entire sequence because of omitted loops, N- and C- termini, while you still want to keep the numbering according to the full master sequence. You might want to use the command also on models by homology generated with the build model command.
Example:
 
 seqmaster = Sequence("ACDEFGHIKLMNPQRST") 
 build string   "--DEFGH-----PQRST"  # dashes are skipped    
 make sequence a_1 name="seqmodel"   # sequence is auto-linked 
 a = Align(seqmodel,seqmaster)       # linked alignment 
 align number a_1 seqmaster 
 # Info> residues of a_def.m renumbered by sequence 'seqmaster' from alignment 'a'    
 display residue label  


align: ICM multiple alignment algorithm


align ali_SequenceGroupName [ tree=|filename= s_epsFileName ]
make a multiple alignment of specified sequences a sequence group resulting from the group sequence s_groupName command. For pairwise alignment use the Align( seq1 seq2 ) function. The algorithm includes the following steps (inspired by corridor discussions with Des Higgins, Toby Gibson and Julie Thompson ):
  1. align all sequence pairs with the ICM ZEGA algorithm, and calculate pairwise distances between each pair of aligned sequence with the Dayhoff formula, e.g. the distance between two identical sequences will be 0. , while the distance between two 30% different sequences will be around 0.5. The distance goes to an arbitrary number of 10. for completely unrelated sequences. The distance matrix Dij can later be extracted from the alignment with the Distance( ali_ ) function.
  2. build an evolutionary tree from Dij with the "neighbor-joining algorithm" of Saitou, N., Nei, M. (1987) to determine the order of the alignment and calculate relative weights of sequences and profiles from the branch lengths. The tree will be saved in the file defined by the tree= s or filename= s option . Starting from version 3.5-2 the aligTree.eps file is NO LONGER saved by default). The so-called Newick tree description string will be saved in s_out .
  3. traverse the tree from top to bottom, aligning the closest sequences, sequence and profile or two profiles. After each Needleman and Wunsch alignment, build the profile.
  4. generate the final neighbor-joining evolutionary tree and write the PostScript file with the tree to disk.

Examples:
 
   read sequences s_icmhome+"zincFing"  
   list sequences               # see them, then ...  
   group sequence alZnFing      # group them, then ...  
   align alZnFing               # align them
   align alZnFing filename="znTree.eps"  # eps file with a tree

 
  read sequence swiss web "12S1_ARATH"
  read sequence swiss web "12S2_ARATH"
  group sequence arath
  align arath

NOTE: this functionality is only available in versions 3.6 and above.


EST,DNA alignment and assembly


[ sim4 ]

align new ali_sequenceGroup [ seq_seed ]
multiple alignment of ESTs and genomic DNA and consensus derivation. This command uses the external the sim4 program to generate pairwise alignments between expressed DNA sequence and a genomic sequence. The program can be downloaded from the http://globin.cse.psu.edu/globin/html/docs/sim4.html site.
The procedure has the following steps:
  • sequences are sorted by length
  • the longest sequence is chosen as the seed sequence unless it is explicitly provided
  • the longest sequence from the remaining set is aligned to the seed sequence using the external sim4 program.
  • the output of this program is parsed and translated into the icm alignment
  • the consensus sequence is created and becomes the master sequence
  • the procedure is repeated until all the sequences are processed
  • the multiple sequence alignment is further cleaned to compress spurious gaps when possible. This cleaning makes the consensus much more compact.

The result of this command is best displayed with the show color ali_ command.

An example:
 
 read sequence "http://www.ncbi.nlm.nih.gov/UniGene/" + \ 
     "download.cgi?ID=5198&ORG=HsLINE=1" # 
 read sequence "../Hs5198" 
 group sequence unique u # squeeze out obvious redundancies and form group 'u' 
 align new u             # form multiple alignment and build consensus 
 show color u 

See also:

align two molecules by their backbone topology


align [ distance ] ms_1 ms_2 [ i_windowSize (15) ] [ r_seqWeight (0.5) ]

This command finds the residue alignment (or residue-to-residue correspondence) for two arbitrary molecules having superimposable parts of the backbone conformations. The structural alignment identification and optimal superposition is primarily based on the C-alpha-atom coordinates, but the sequence information can be added with a certain weight (the default value of r_seqWeight is 0.5 which was found optimal on a benchmark). The structural alignment algorithm is based on the ZEGA (zero-end-gap-alignment) dynamic programming procedure in which substitution scores for each i,j-pair of residues contain two terms:
  • structural similarity in a i_windowSize window between two fragments surrounding residues i and j, respectively. This similarity is calculated as local Rmsd of the residue label atoms (these atoms are C-alpha atoms by default but can be reset to other atoms with the set label command, e.g. set label a_*.//cb ). If the option distance is specified the deviation of the interatomic distances between equivalent pairs of atoms (so called distance rmsd ) is calculated instead of a more traditional root-mean square deviation between atom coordinates of equivalent atoms. The latter method is less accurate but an order of magnitude faster.
  • sequence similarity (if r_seqWeight > 0.). Average local sequence alignment score in the i_windowSize window is calculated for i,j-centered pair of fragments. In this sense this sequence similarity is different from the one used in pure sequence alignment (see the Align function), in which just the i,j residue pair is evaluated. The default value of r_seqWeight of 0.5 is rather mild (about a half of the structural signal).

The output:
  • ali_out contains structural alignment (if sequences linked to the molecules do not exist, they will be created on the fly). The alignment can be further edited with the interactive alignment alignment editor.
  • as_out contains the residue selection of the aligned residues in the first molecule
  • as2_out contains the residue selection of the aligned residues in the second molecule
  • M_out , the matrix of local structural/sequence similarity in a window is retained and can be visualized by:

Example:

 
read pdb "1ql6"
read pdb "2phk"
align a_1ql6. a_2phk.
make grob color 10.*M_out name="g_mat # x,y,z scales 
display g_mat 
# or 
plot area M_out display grid link 

See also:
  • Align( seq_1 seq_2 distance|superimpose ). This function creates the first unrefined structural alignment as described above.
  • find alignment which refines initial structural alignment.
The overall result of the align command is equivalent to:
 
  a = Align(... superimpose )  # superposition/RMSD based local str. alignment 
  a = Align(... distance    )  # distance RMSD based local str. alignment 
 
  find a superimpose 4.0 0.5 

Example:
 
  read pdb "1brl" 
  read pdb "1nfp" 
  rm a_*.!A 
  display a_*.//ca,c,n 
  color molecule a_*. 
  align a_2.1 a_1.1 
  center 
  show String(as_out) String(as2_out) 
  color red as_out 
  color blue as2_out 
  show ali_out 


align heavy command for multiple alternative structural alignments.


align heavy rs_1 rs_2 [ r_rmsd ] [ i_windowSize [ i_minFragment]] [ r_elongationWeight]
This method, as opposed to the default align ms_1 ms_2 generates many possible solutions and does not depend on sequential order of the secondary structure elements. However, it leads to a combinatorial explosion and is intrinsically less stable computationally, and generally requires more time. The command finds the optimal 3D superposition between two arbitrary molecules/fragments (two residue selections rs_1 and rs_2 ).
The procedure generates structural fragments of certain initial length and superimposes all of them to calculate the structural similarity distance. Then the "islands" of similarity are merged into larger pieces. This process is controlled by the following arguments: i_windowSize is the residue length of structural fragments for the initial fragment superposition. Fragment pairs with the rms deviation less than r_rmsd are then combined, giving composite solutions of total residue length larger than i_minFragment. Acception or rejection of the composite solutions is governed by the following score (the smaller, the better)
score = rmsd - (1.37 + Sqrt(1.16 * length - 15.1)), length >= 14
If length > 14 , we use linear extrapolation of the score dependence:
score = rmsd - (1.37 + 1.068*(length-13))
The score is required to be less than r_rmsd. Practically, for longer fragments one can find much larger RMS deviations according to the length correction of the score.
Defaults:
  • r_rmsd = 1. A
  • i_windowSize = 15 residues
  • i_minFragment = i_windowSize
  • r_elongationWeight=0.1
There may be several different reasonable solutions. All the solutions are sorted, shown and stored in the memory. The two output selections as_out and as2_out contain the best scoring solution. Any solution can be loaded and displayed. Additionally, a residue alignment is created for each solution. The decision about which residues are aligned is based on the overall score described above for the of combined fragments.
See also: How to optimally superimpose without the residue alignment
Example:
 
 read pdb "4fxc" 
 read pdb "1ubq" 
 display a_*.//ca,c,n 
 color molecule a_*. 
 align heavy a_1.1 a_2.1 12 1.5 .1 
 center 
 load solution 2            # load the second best solution 
 color red  as_out 
 color blue as2_out 
 for i=1,10 
   load solution i 
   color molecule a_*. 
   color red  as_out 
   color blue as2_out 
   pause                     # rotate and hit 'return' 
 
 endfor 
Note. Increase i_minFragment parameter (12 in the above example) to something like 20 if the program hangs for too long. Interrupt execution with the ICM-interrupt (Ctrl \) if you want only the top solutions.



append (commands)


[ Append sequence | Append stack | Append column ]

There is a family of commands starting with the append keyword. They are usually used to add subelements to a compound object like an alignment or a stack. In many cases ICM uses add syntax instead of append.

Appending sequences to a sequence group or an alignment


append ali_seqGroup seq_1 seq_2 .. .
appends sequences to a sequence group. This may be required if you formed a sequence group for future alignment or filtering/compression and you want to append additional sequences to it.

Examples:

 
read sequence group "bunch.seq" name="xx" # group xx is formed 
append xx my_seq  # appending your sequence to xx 
group xx unique   # filter out identical ones 
align xx 


read sequence swiss web "12S1_ARATH" 
read sequence swiss web "12S2_ARATH"
group sequence name="arath"
read sequence swiss web "14310_ARATH"
append arath 14310_ARATH
align arath

Appending a molecule or a ligand stack to an existing stack


append stack s_ligandStackFileName [i_maxConf]

append stack os_ligandObject

this command takes a stack which corresponds to a receptor object and appends each conformation in the stack with a conformation of the ligand. If the ligand conformation can be taken from either from a stack file, this command will combine each conf from the main stack with all conformations from the file. The i_maxConf argument will set the limit on how many conformations are taken from the ligand stack (i.e. append stack "lig.cnf" 1 will combine only the first conformation of the ligand )

If the second argument is an ICM object, each conf of the current stack will be extended with the variables from the ligand. Now the ligand object can be appended to the receptor object with the move command and the new combined object can use the expanded stack.


build string "ACDEF"  # the "ligand" peptide
rename a_ "Lig"
translate a_ {10. 0. 0.} # shift not to overlap with a_Rec.
montecarlo v_//!?vt*     # created Lig.cnf stack

build string "RSTVW"  # the "receptor" peptide
rename a_ "Rec"
montecarlo v_//!?vt*     # created Rec.cnf stack

move a_1. a_2.    # ligand must be the 1st argument
append stack "Lig.cnf" 4 # combine up to 4 best ligand confs
minimize stack    # minimizes each stack conf
load conf 1       # check them out

append two tables via two columns with matching values


append t1.A t2.B
Append rows of table t2 to table t1 by rows corresponding to unique column t2.B . The t1.A column values do not need to be unique.

 
group table people {"J","C","M"} "p" {"MS","MS","MS"} "orgid" 
group table orgs  {"MS"} "id" {"Molsoft"} "name" 
append people.orgid orgs.id 
people 
 #>T people 
 #>-p-----------orgid-------name------- 
    J           MS          Molsoft 
    C           MS          Molsoft 
    M           MS          Molsoft 

This command is a particular case of a more general join command.

See also the add table command for adding rows from a column with identical column structure (e.g. add t tt ).

assign


[ Assigns structure | assign sstructure segment ]

assign sstructure: derive secondary structure from a pattern of hydrogen bonds


assign sstructure rs_ [{ s_SecondaryStructTypeCharacter | s_SSstring }]
Manual assignment of a desired secondary structure annotation to a residue fragment
assign specified secondary structure to the selected residues rs_ , e.g.
 
 read pdb "1crn" 
 assign sstructure a_/* "_"  # make everything look like a coil 
 cool a_ 
 assign sstructure a_/1:10 "HHHH_EEEEE"   
 cool a_ 


This command does not change the geometry of the model, it only formally assigns secondary structure symbols to residues.
Note: to change the conformation of the selected residue fragment, according to a desired secondary string, use the ICM -object and the set command applied to both sequences and molecular objects.

Automated derivation and assignment of secondary structure from atomic coordinates
assign sstructure rs_
If the secondary structure string is not specified, apply ICM modification of the DSSP algorithm of automatic secondary structure assignment (Kabsch and Sander, 1983) based on the observed pattern of hydrogen bonds in a three dimensional structure.
The DSSP algorithm in its original form overassigns the helical regions. For example, in the structure of T4 lysozyme (PDB code 103l ) DSSP assigns to one helix the whole region a_/93:112 which actually consists of two helices a_/93:105 and a_/108:112 forming a sharp angle of 64 degrees. ICM employs a modified algorithm which patches the above problem of the original DSSP algorithm. Assigned secondary structure types are the following: "H" - alpha helix, "G" - 3/10 helix, "I" - pi helix, "E" - beta strand, "B" - beta-bridge, "_" or "C" - coil.
Examples:
 
 nice "1est"       # notice that many loops look like beta-strands 
 assign sstructure # now the problem is fixed 
 cool a_ 

See the set rs_ s_SecStructPattern command to actually set new phi, psi angles to a peptide backbone according to the string of secondary structure.

assign sstructure segment


assign sstructure segment [ ms_molecules ]
create simplified description of protein topology (referred to as segment representation). Segments shorter than segMinLength are ignored. The current object is the default.
See also show segment, ribbonStyle, display ribbon.

break


is one of the ICM flow control statements. It permits a loop ( e.g. for or while ) to be broken before calculations have completed.
Examples:
 
   for i = 1, 8 
     print "Now i = ", i, "and it goes up" 
     if (i == 4) then 
       print "... but at i=4 it breaks, Ouch!" 
       break 
     endif 
  endfor 
See also goto .

build


[ Build atom | Build sequence | Build model | Build loop | Build smiles | Build string | Build hydrogen | Build molcart ]

The build family of functions allows to create molecular objects It also adds implied hydrogens ( build hydrogen ) to a molecule and to find a loop in a database ( build loop)

build one atom and rebuild hydrogens


build atom as1 [simple] [s_elementName=("c")] [i_bondType=(1)]
by default it will add a carbon to the selected atom in a non-ICM object and rebuild hydrogens for the affected atoms. Use the strip command for ICM objects.

Options and arguments:

  • simple does not rebuild hydrogens.
  • s_elementName is a string with the name of the chemical element.
  • i_bondType is 1 for a single bond (the default), 2 for a double bond and 4 for a triple bond.

Example:


build smiles "CC(C)Cc1ccc(cc1)C(C)C([O-])=O" name="ibuprofen"
strip a_ibuprofen.
build atom a_ibuprofen.m//c1 "n"
build atom a_ibuprofen.m//c1 2

See also:

NOTE: this functionality is only available in versions 3.6 and above.

Building object from sequence file


build s_IcmSeqFileName [ library= { s_libFile | S_libFiles} ] [ delete ]
reads s_IcmSeqFileName.se ICM-sequence file and builds an ICM molecular object. This sequence file is different from a simple sequence file and contains three (sometimes four) character residue names defined in the icm.res residue library file (try show residue types to see the list).

Use command build string if you want to build an object from a string with one letter coded sequences or a named sequence. E.g. build string "ASDGF" or "ASD;DERR" or "nh2 ala his cooh"

To get a D-amino acid instead of L-ones simply use D as a prefix: Dala Darg. Specify N- or C-terminal modifiers directly in the file if needed. The build command will create them in some default conformation (extended backbone with different molecules oriented around the origin as a bunch of flowers). Several molecules can be specified in the ICM sequence file.
Residue names may contain numbers (i.e. 4me ). However, the residue numbers with a modification character, such as 44a, 44b should contain a slash before the modification character (i.e. 44/a , 44/b ). An example in which we create a sequence of residues ala and 4me with numbers 2a and 2b, respectively: "se 2a ala 2b 4me".
The library option lets to temporarily switch the library file. The same result may also be achieved by redefining the LIBRARY.res array of the LIBRARY table.
The delete option temporarily sets the l_confirm flag to no and the old object with the same name gets overwritten. Examples:

 
 build "def"  # def.se file
 build s_icmhome + "alpha.se"  # alpha.se file  
 build "wierd" library="mod.res"  # get residues from mod.res  
# 
 LIBRARY.res = {"icm","./myres"} 
 build "s"  

Building model by homology


[ Homology steps | Loop search | The output ]

build model seq_1 seq_2 ... ms_Templates ... [ ali_1 ...] [ margin= { i_maxLoopLength, i_maxNterm, i_maxCterm, i_expandGaps }
build a comparative model (homology model) of the input sequences based on the similarity to the given molecular objects. The margin arguments:
namedefaultdescription
i_maxLoopLength 999longer loops are dropped
i_maxNterm 1the maximal length of the N-terminal model sequence which extends beyond the template
i_maxCterm 1the maximal length of the C-terminal model sequence which extends beyond the template
i_expandGaps 1additional widening of the gaps in the alignment. End gaps are not expanded
    Possible modes:
  • simple one-to-one mode: build model seq_1 [ms_1] [ali_1]
  • N sequences - N corresponding molecules: build model seq_1 seq_2 .. seq_N ms_1,2,..N This mode requires the minimize tether command to complete the construction.

Examples:
 
 l_autoLink = yes 
 read pdb "x"  
 read alignment "sx"  
 build model ly6 a_  
 ribbonColorStyle = "alignment" # grey-gaps, magenta-insertions 
 display ribbon 


 read pdb "2ins"  # multichain  
 a = Sequence( "GIVEQCCASV CSLYQLENYC N" )
 b = Sequence( "VNQHLCGSHL VEALYLVCGE RGFFYTPKA" )
 c = a
 d = b
 build model  a b c d a_1. 
 minimize v_//V "tz" 1000
# or   minimize tether
# Now optimize the side chains 
 selectMinGrad = 1.5 
 set vrestraint a_/* 
 montecarlo fast v_/!I/x*   
# !It means residues which are not Identical to their template residues 
# use  refineModel to energetically optimize the model 

The algorithm performs the following steps:


Alignment adjustment: modifies the alignment according to i_expandGaps, and prepare a sequence with the ends and the long loops truncated according to the alignment and the { i_maxLoopLength , i_maxNterm , i_maxCterm } parameters.
Building a straight polypeptide from the model sequence: builds a full-atom polypeptide chain for this new sequence. The residues in your model are numbered according to the template and all the inserted loops residues are indexed with 'a','b', etc. E.g. the numbering may look like this: 200,201,203,204,204a,204b,204c,205 ... This numbering allows one to follow more easily the correspondence between the template and the model. If you do not like this numbering scheme, just use the
 
align number a_/* 
command and the model residues will be renumbered from 1 to the number of residues.
Backbone topology transfer: inherits the backbone conformation from the aligned (but not necessarily identical) parts of the known template
Identical side-chain building: inherits conformations of sidechains identical to their template in the alignment
Non-identical side-chain placement: assigns the most likely rotamer to the side chains not identical in alignment. If you want to do more than that apply:
 
set vrestraint a_/*  # assigns the rotamer probabilities 
montecarlo fast v_/Cx/x* # x* selects for all chi (xi) angles 
You can also manually re-optimize any side chains either interactively (right-mouse click on a residue atom, then select Shake Amino-Acid Side-Chain) or from a script, e.g. for residue 14:
 
set vrestraint a_/*  # assigns the rotamer probabilities 
montecarlo v_/14/x*   
ssearch v_/14/x*     # systematic conformational search for the 14-th sidechain 

Loop searches:


searches the icm.lps which may contain entire PDB-database for suitable loops with matching loop ends and as close loop sequence as possible, inserts them into the model and modifies the side-chains according to the model sequence.
The loop file can be easily customized, updated and rebuilt with the write model [append] command in a loop over protein structures. To use your custom loop file, redefine the LIBRARY.lps variable.
Loop refinement and storing alternatives: adjusts the best loops found and keeps a stack of loop alternatives which can later be tested (see the Homology gui-menu).


The output


The build model command returns the following variables:
LoopTable master table containing list of all the loops, their conformation in alphanumeric code, a measure of the deviation of the database loop ends and the model attachment sites, the loop length and the numerical conformation type (not really important). E.g.

 
#>T LoopTable 
#>-1_Loop------2_Conf------3_Rmsd------4_Nof-------5_Type----- 
   a_ly6.a/7:10 31R21       0.1         11          1           
   a_ly6.a/60:63 1RRR32      0.1         8           1           
   a_ly6.a/43:46 211331RRRR  0.240658    4           1           

Individual loop tables
Tables called LOOP1 , LOOP2 , etc. for each inserted loop. The tables contain the coded conformational string, relative energy, the position of the offset in the structure database file ( offset ) to be able to extract this loop again, and the rmsd of the loop ends. Example:
 
icm/ly6> LOOP1 
#>T LOOP1 
#>-Conf--------energy------offset------rmsd------- 
   31R21       0.          3623594     0.092104    
   31RR2       1.519275    3427772     0.083372    
   R1121       1.612712    3750108     0.097777    
   R1R32       1.639177    1529882     0.087113    
   R1RR2       1.880638    3806768     0.079335    
   31R32       3.714823    4561270     0.053853    
   R3RR2       4.531406    4003324     0.042881    

Writing and restoring the tethers Objects, alignments and tethers can be written to a single binary project file (see write binary all )
Trouble shooting build model may crash. A possible reason of the crash is that the pdb file is not correctly parsed due to formatting errors. Many pdb files still have formatting errors, especially those which are generated by other programs or prepared manually. In this case the read pdb command is trying to interpret the field shifts and, as with any guess work, frequently gets it wrong. For example, try 2ins and you will see that the atom or residue names are shifted. To fix the problem, try to use the exact option of the read pdb command.

Building loop to a model by homology


build loop rs_fragments
rebuild specified loop based in a PDB-database search (see build model ).
An example:
 
 read object s_icmhome+"crn" 
 build loop a_/20:26  # rebuild this loop 

Building object from a chemical smiles string


build smiles s_smiles_string [ name= s_ObjName]

create an ICM-object from the smiles -string, respectively.
Set l_readMolArom to no if you do not want to assign aromatic rings from a pattern of single and double bonds (and formal charge and bond symmetrization for CO2, SO2, NO2or3, PO3 ) upon building. To suppress suppress the symmetrization and consequential charging of CO2, set the l_neutralAcids flag to yes .

Examples:

 
build smiles "CCO"   # ethanol 
 
build smiles "Oc(cc1cc2)ccc1cc2N" 
 
build smiles "Oc(cc1cc2)cc(ccc3)c1c3c2" 

build smiles "C/C=C\C" # cis-2-butene

build smiles "C/C=C/C" # trans-2-butene
 
              # dicoronene 
build smiles "c1c2ccc3ccc4c5c6c(ccc7c6c(c2c35)c2c1c1c3c5c6c"+\ 
             "(c1)ccc1c6c6c(cc1)ccc1ccc(c5c61)cc3c2c7)cc4" 
 
              # NAD 
build smiles "[O-]P(=O)(OCC1OC(C(O)C1O)N1C=2N=CN=C(N)C=2N=C1)"+\ 
             "OP(=O)([O-])OCC1OC(C(O)C1O)N=1C=CC=C(C=1)C(=O)N" 
 
              # Hexabenzo(bc,ef,hi,kl,no,qr)coronene 
build smiles "c1c2c3c4c(ccc3)c3c5c(c6c7c(ccc6)c6c8c(ccc6)c6c9"+\ 
             "c(ccc6)c(cc1)c2c1c9c8c7c5c41)ccc3"  
 
              # rubrene 
build smiles "c1c2c(c3ccccc3)c3c(c(c4ccccc4)c4c(cccc4)c3c3ccccc3)"+\ 
             "c(c2ccc1)c1ccccc1" name="rubrene"

Somtimes the build smiles command is not sufficient. The molecule needs to be optimized in the mmff force field and several conformations need to be sampled. A more rigorous conversion is provided by the convert2Dto3D macro.
See also: Smiles , find molecule.

Building object from string


build string s_IcmSequence [ name= s_ObjName ] [ delete ]
create an ICM-object from a s_IcmSequence string (see the build command above). To get a D-amino acid instead of L-ones simply use D as a prefix: Dala Darg. Specify N- or C-terminal modifiers directly in the file if needed. The build command will create them in some default conformation.

The build string command also understands short one line version of the full format. The short format looks like "ASD" or "ala his" and can not start from "ml " or "se ".

The possibilities are the following:

  • one letter code, - it needs to be specified in upper case letters, e.g. "DD";
  • full three-four letter code, e.gg. "nter ala hise Dala cooh"
  • multiple molecules - just use a comma, a semicolon or a dot as a separator, e.g. "WWWW;AAAA;EEE" or "ala his trp; nh3+ gly coo-"
    NOTE: the above option is only available in versions 3.6 and above.

Option delete temporarily sets the l_confirm flag to no and the old object with the same name gets overwritten.
Examples:
 
   build string "ADGHRTE" # the charged terminal groups will be added
   build string "ADGH;RTE" # two peptides, a and b 
   build string "nter ala Dhis cooh" name="pep"  # one peptide named a_pep. 
   build string "ml a \nse nh3+ his coo- \nml b \nse trp" # molecules a and b  
   build string IcmSequence("GHFDSFSDRT","nter","cooh") # translate and add termini 
# 
# Using alias  BS   build string "se $0" 
   BS ala his trp   

See also: Sequence, IcmSequence.

Building hydrogens according to topology and formal charges.


build hydrogen [ as_heavyAtoms ] [ i_forcedNofHydrogens ] [cartesian]
adds hydrogens to the specified heavy atoms according to their type and formal charge. All heavy atoms of the current object are used by default. If your have hydrogens already and their configuration is wrong, you can delete them with the delete hydrogen command. The number of hydrogens may be enforced if the optional i_forcedNofHydrogens argument is specified.

Option cartesian means that no new hydrogens are added, but, rather, the existing ones are set to new coordinates according to the heavy atoms (a better syntax for this action is set hydrogen ).

See also the set bond type command, set hydrogen .
Examples:

 
  read mol s_icmhome+ "ex_mol"  # several small molecules  
  display a_4. 
  build hydrogen a_4.  # added and displayed  
#  
  undisplay
  display a_3.
  build hydrogen a_3.
# move one of the nydrogens  
  build hydrogen a_3. cartesian # should put the hydrogen back at a correct position

Building molcart indices for substructure, similarity or exact search


build molcart {s_tableName|S_tableNames} [sstructure|similarity|exact]

builds (or rebuilds) various keys for molcart table.

call


call s_ScriptFileName [ only ]
invokes and executes an ICM-script file. End the script with the quit command, unless you want to continue to work interactively, or use it in other script.
The option only allows to suppress opening the script file if the call command is inside a block which is not executed. By default the script file is opened and loaded into the ICM history stack anyway, but the commands from the file are not executed.
The absolute path of the script can be obtained by calling the Path ( last ) function.
Example:

 
  call _startup             # execute commands from _startup file  
  show Path( last )

Example of calling scripts inside conditional expressions.

if Type( CONSENSUS ) != "table" then
 call _startup only # only means do not read if the table is already loaded
endif


center


center [ { as_ | grob } ] [ only ] [ static ] [ margin= r_margin ]
centers and zooms the screen on selected atoms as_ or graphics objects. Default objects: all existing atoms and graphics objects. The r_margin argument is given in Angstrom units and can be used to set a relative size of the selection and the frame. Normally all dimensions of the molecule/grob are taken into account, so that the molecule can be rotated without changing scale.
Options:
  • only : do not rescale, translate only, i.e. move the selected atoms to the center of the graphics window
  • static : scale only according to the visible X-Y dimensions and the margin. Do not take the Z-dimension into account in the size calculation as if you do not intend to rotate objects. That implies an assumption that the orientation of molecules/grobs/maps will not be changed.

Examples:
 
   nice "1est" 
   center                        
   center Sphere ( a_/15:18 )    
   center a_/1:2 only  # keep the scale 
 
   read grob s_icmhome+"beethoven" # a genius  
   display beethoven smooth 
   center beethoven static   # 10 A margin 


clear


[ clear-error ]

clear

clear terminal screen
clear selection clear the graphical selection as_graph

Example:


nice "1crn"
as_graph = a_/1:5 # select five residues
clear selection # nothing again

clear graphic [ os_ ] clear display properties , graphic representation memory and reset the graphic planes to the default.

clear error

clear all error and warning bits previously set by ICM. See also Error ( i_code )



color


[ Color specification | Color object ]

The color command colors different shell objects, their parts, or different graphical representations with by colors specified in various ways.

See also set color to set atom or residue color directly and without graphics.

Specifying colors in ICM


There are various ways to specify a color in ICM: by name, index or RGB representation.

color_name | color[i_index] | i_Color | r_Color | rgb=rgb_color

Specifying color by name:


color red
Other color name examples: black, white, grey, blue, red, yellow, green, orange, magenta, lightblue. Color names may be observed and changed in the icm.clr file.

Requesting contrasting colors by index:


color color[4]
This call uses color number 4 from the list of "named" colors (first section of the icm.clr file). Colors with their numbers can be listed by the show color command and their total number is accessible via the Nof( color) function. This mode is useful if you need to color selected elements with contrasting colors rather than with a smooth spectrum.

Example:


  read pdb "1crn"
  display ribbon a_1crn.
  show colors 
  color a_/1:5/* color[89] 
  for i=1,Nof(a_/*) 
    color a_/$i color[i]       # speckled coloring 
  endfor 

Specifying color by index:

color 3

Color indices are taken from the "rainbow" section of the icm.clr file. Currently there are 128 colors (i=0,127) in this section and they form a smooth transition from blue to red via white (not really a rainbow). You may change the "rainbow" colors in the icm.clr file. Number 128 becomes blue again. Using integer color indices is convenient for automatic coloring within ICM loops.

Example:

 
   display "Colors" 
   for i=1,255 
     color background i 
     print i 
   endfor 
See also color background example .

Specifying colors interpolated between indexed colors:


color 4.5 

The color 4.5 will be the average between the "rainbow color" 4 and "rainbow color" 5.
Specifying colors by their RGB representation

Color is defined as a combination of red, gren and blue componets. The triple may be specified in different formats:

rgb = R_3rgb

- as an array of 3 reals in 0..1 range

rgb = I_3rgb

- as an array of 3 integers in 0..255 range

rgb = s_#rrggbb

- as a string where each component is deined by two characters in hexadecimal form. Optionally prefixed with a hash symbol ("#").

Examples setting magenta color (mixture of red and blue):


color rgb={255,0,255}
color rgb={1.,0.,1.}
color rgb="#ff00ff"
color rgb="ff00ff"

In case the requested RGB color is not available for the graphics system, ICM finds the closest color.

Coloring molecular objects


The main color command:
color [ as_ ] graphic_representaion [ color_spec ]

color [ as_ ] graphic_representaion [ I_colors | R_colors ] [window = R_2MinMax]

graphic_representation, when specified, must be one of the following

wire | hbond | cpk | ball | stick | xstick | surface | skin | site | ribbon [base]

This command colors selected atoms ( as_ ) or graphics object(s) according to the specified color. It is possible to either specify a single color color_spec, or provide an array ( rarray or iarray ) of colors to color each element of the selection according to a certain property, as electric charge or Bfactor.

The scale is determined by the minimal and the maximal elements of the array, independently of the array length. First the numbers in the array are scaled so that its minimum corresponds to the first color in the "rainbow" section and its maximum to the last color. Then the scaled numbers are applied sequentially to the elements of the selection. If the number of elements in the array is shorter than the number of elements in the selection, the array is applied periodically. If the color array is longer than the selection, the excessive numbers are not used for coloring but (attention!) they will be used for scaling.

The window={ minValue, maxValue } option allows to provide a range for color mapping. It will be used instead of the array minimum-maximum value range as the range from which the color array elements will be mapped into the rainbow colors. Moreover, values in the color array will be clamped to be in the window range.

In the following example the Bfactor(a_/ simple) values which may range from large negative values to large values will be clamped to the [4.,40.] range.


  nice "1ekg"
  color ribbon a_/ Bfactor(a_/ simple) window=4.//40.
Another example:
 
  read object s_icmhome+"crn"
  display a_crn.
  color a_//* Charge(a_//*) window={-1.,1.}

It is also possible to show a color bar in the graphics window by changing the GRAPHICS.rainbowBarStyle property.

Each of the command arguments has a default:

  • objects as_: the current object ( a_ ) only. Hint: to color all objects, use a_* .
  • graphic_representation: all except ribbon. Ribbons should be colored explicitly using a color ribbon command.
  • color_spec. The default coloring is by atom type, except for the ribbon representation which is colored by secondary structure by default.
All default values can be changed by editing the icm.clr file.

In DNA and RNA ribbons, bases can be colored separately (e.g. color ribbon base a_1/* white ), the default coloring being A-red, C-cyan, G-blue, T or U-gold.

Examples of how the defaults work:

 
 nice "1crn" 
 display       # also displays wire 
 color         # all except ribbon colored by atom type 
 color ribbon  # only ribbon of a_ by secondary structure type  
 color ribbon red         # only ribbon as specified 
 color a_/1:10 ribbon yellow # parts


More examples:

 
 build string "ASDWER"     # hexapeptide 
 display
 color a_/1:4 green    # the first four residues in green  
 color                 # return to default colors by atom type  

 
 read pdb "1crn"
 display a_1crn. only 
                       # color atoms according to their B-factor  
 color a_1crn.//* Bfactor(a_1crn.//*) 
                       # crambin's ribbon  
                       # from blue N-term to red C-term gradually  
 display a_/* ribbon only 
 color a_/* Rarray(Count(1 Nof(a_/* ))) ribbon 
 
                       # another crambin's ribbon  
                       # from blue N-term to red C-term gradually  
                       # thick worm representation 
 assign sstructure a_/* "_"  
 GRAPHICS.wormRadius= 0.9 
 display a_/* ribbon only 
 color a_/* Count(1 Nof(a_/* )) ribbon 

How to color grob surface by depth


[ Color molecule | color background | color by alignment | color grob | color label | color map | color volume ]

color accessibility g_mesh [ r_maxShade ]

modify the color of each surface element of a grob by mixing its own color with the background depending on the burial of the surface element. Repeated application of the command or using a larger r_maxShade (the default is 0.8) generates a more dramatic shading of the shape.

Example:


color accessibility g_electro 0.5
NOTE: this functionality is only available in versions 3.6 and above.


Uniquely coloring by object, molecule, residue or atom


color graphic_representation [ as_molecules ] [object|molecule|residue|atom]
a special command to color the displayed and selected molecules differently. The graphic representation field can be either empty, or one of those: wire xstick cpk surface skin ribbon, residue label, atom label, site label, variable label . E.g. select graphically some atoms and do this:


color xstick as_graph & a_*.//c* molecule  
color ribbon as_graph object
color cpk as_graph molecule
color residue label as_graph residue



color background


color background color_spec

sets the background to the specified color color_spec in one of the supported formats .

Examples:


color background blue 

color background lightyellow

color background rgb={255,255,255} # white. integers in 0..255 range

color background rgb={0.,1.,0.} # green. reals in 0.. range

See also: rgb, color background example .



color by alignment


color as_ [wire|cpk|skin|ribbon|xstick|ball|stick|surface..] alignment
colors specified graphics representations of the selected residues by the colors of an alignment as you see it in the alignment window of the Graphics User Interface. The color of a residue is controlled by the following factors:
  • residue type
  • consensus character at the residue position in the alignment
  • colors as provided by the CONSENSUSCOLOR table.
Note that the CONSENSUSCOLOR table can be divided into sub-sections, and the active subsection can be selected from GUI.
Example:
 
  read sequence s_icmhome+"sh3" 
  nice "1fyn" 
  make sequence a_1  # extract 1st sequence 
  group sequence sh3 
  align sh3 
   
  color a_1 ribbon alignment 
  display skin white a_1 a_1 
  color a_1 alignment   # colors all representations including skin 

color grob


[ Color grob unique | Color grob matrix | Color grob by atom selection | Color grob map | Color grob potential ]

Color is a powerful mechanism of showing extra information on ICM grobs ICM grobs may have individual colors assigned to each vertex, which allows to use grob coloring to illustrate properties of 3D surfaces.

The simplest way to set grob color is to paint it to a single color.

color g_grobName color_spec

colors the whole g_grobName grob to the color_spec color.

color grob color_spec

colors all grobs to color_spec.

Check out the color specification section for available color_spec options.

Example:


torus = Grob("TORUS",3.,1.)
display torus
color torus black # paint it black
color background white # this should improve the visibility
color torus rgb={127,255,212} # aquamarine, as some people call it

Automatic assignment of different colors to different grobs


color grob unique
In addition to the main color command which colors grobs there is a special command to automatically assign the displayed grobs to different colors.

See example for the split grob command.

Coloring grob by matrix of RGB values for each vertex.


color g_grob M_rgbMatrix
allows to set individual colors to grob vertexes. Colors are specified in RGB format in the M_rgbMatrix.Each row of the matrix is an RGB triple. This type of matrix may be obtained by the Color( g_grob ) function.

Examples:


torus = Grob("TORUS",3.5,0.5)
display torus smooth
n = Nof(torus)
R_rgb = Count(1 n/2)/Real(n/2) // Count(n-n/2 1)/Real(n-n/2)
add matrix M_rgb R_rgb
add matrix M_rgb Rarray(n,0.3)
add matrix M_rgb Rarray(n,0.7)
color torus Transpose(M_rgb)

This command allows to create special effects, like gradual disappearance of a grob into background:


# set the scene
color background black

# uncomment these lines to get a more sophisticated example
# torus = Grob("TORUS",3.5,0.5)
# display torus smooth 
# color torus blue

# the active grob
g = Grob("SPHERE",3.,5)  # a wire sphere  
display g smooth 
color g Random(Nof(g),3, 0., 1.) # color randomly 
M_colors = Color(g)               # extract current colors 
# make the sphere disappear (modern poetry)  
for i=1,20    # shineStyle = "color" makes it disappear completely 
 color g (1.-i/20.)*M_colors  
endfor         
for i=20,1,-1 # bring the sphere back  
 color g (1.-i/20.)*M_colors  
endfor 

Coloring grob by proximity to atoms


color g_grobName as_closeAtoms color_spec

colors vertices of the grob which are less than GROB.atomSphereRadius to any of the selected atoms. The default value for the radius is 4Å.

See color specification for the definition of color_spec.
See also: Grob( g R_6) function to return a patch of certain color.

Example:


nice "1crn"
make grob skin a_1crn. name="g_1crn"
display g_1crn
color g_1crn green
color g_1crn a_1crn.//1:60 red # color a patch by atom proximity

See also: make grob skin, make grob potential .

Coloring surfaces by 3D scalar field


color g_grob map map_Name I_transferFunction R_2mapValueBounds [ color_spec ]
colors vertices of the g_grob by the values of the map_Name . The map values at each grid point are first clamped into the R_2mapValueBounds range, then this range is divided according to the number of elements in the transfer function and each point is colored according to the value of the transfer function. The optional color_spec parameter is explained in the color specification section.
The new color will be mixed with the current color of grob points. Therefore if you want to color each of 3 RGB channels with a different normalized property value, first color the grob black, and then color with the red , green , or blue color depending on which channel you intend to use. Note that zero in the tranfer function correspond to no color . Corresponding grob nodes will not be colored.
Transfer function is the same to the one in color map but has certain differences. This function (e.g. {0 0 0 1 2 3} ) contains any number of positive integers. 0 means "do not color", and each positive value is a scaling factor for the color provided as an argument, or a parameter to select a color from a predefined rainbow. In the above example, the R_2mapValueBounds range will be divided into 6 ranges and each value range will be colored accoringly.
Example in which we color the vertices of a grob by inverted values of truncated hydrophobic potential:

 
  read obj s_icmhome+"data/xpdb/1sre.ob"
  display a_	
  make grob skin a_2 a_2 name="g_pocket"        # create g_pocket 
  make map potential "gs" Sphere( g_pocket a_1) 
  compress g_pocket 1. 
  color g_pocket black 
  color g_pocket map -m_gs { 0,0,0,3,4,5 } { 0. 0.5  } green           
  display g_pocket
  h = Transpose( Color( g_pocket ) )[2]  # extract hydrophobicity 

Coloring grob by electrostatic potential


color grob potential [ fast ] [ reverse | simple ] ms_sourceAtoms
(REBEL feature) calculates electrostatic potential waterRadius away from the surface of the g_skin graphics object and color surface elements according to this potential from red to blue. Important the location of the center of the water probe is determined by the grob normal ( you can change it with the set g_ reverse command). If you compute the potential at a blob outside the molecule but with the normals point outwards, use the reverse option. To compute potential without any positional correction including normals use the simple option.
The potential is calculated either by the REBEL boundary element solution of the Poisson equation, or, if option fast is specified, by a simple Coulomb formula with the dielConstExtern dielectric constant (78.5 by default).

The local value of potential is clamped to the range [ -maxColorPotential, +maxColorPotential ]. It means that a potential larger than maxColorPotential is represented by the same blue color, while values smaller than maxColorPotential are represented by the same red color. The real range is reported by the command and you can adjust maxColorPotential to cover the whole range. To suppress the absolute maxColorPotential threshold and use auto-scaling instead set maxColorPotential to 0. The color bar with values will appear according to the GRAPHICS.rainbowBarStyle preference. There are two macros to generate potential-colored skins: rebel and rebelAllAtom
The second one (given below) considers all the atoms (including hydrogens) with their charges.
The mean value of the potential at the surface is returned in r_out , and the root mean square deviation of the potential is return in r_2out shell variables, respectively. The averaging is free from bias due to uneven density of grob points. It uses equal size cubes distributed evenly over the surface. The number of representative cubes used for the calculation is return in i_out .

Examples:

 
read object s_icmhome + "crn"
display a_1
make grob skin a_1 name="g_crn"
make boundary a_1
display g_crn
color g_crn potential
See also: electroMethod, make boundary, delete boundary, show energy "el", Potential( ).

color label


color label [ as_ ] color_spec

color label as_ [ I_colors | R_colors ]
Colors labels associated with the selected residues or atoms. A simple option is to specify a single color using color specification formats. It is also possible to provide colors for each atom using an iarray I_colors or rarray R_colorsIf no atom selection is specified, all labels are colored.
Examples:

 
 read object s_icmhome + "crn" 
 display a_//n,ca,c white 
 display label residue 
 color label a_/* Count(1 Nof(a_/*)) 
 #
 color label a_/5:10 magenta 


 read object s_icmhome + "crn" 
 display a_//n,ca,c white 
 display label residue 
 color label lightyellow 
See also: display label, color object, resLabelStyle .

color map


color map_Name [ I_colorTransferFunction ] [ R2_fromTo ] [ auto ]
color the current or the specified map according to the color transfer function supplied as I_colorTransferFunction.
The default: By default the maps are colored in such a way that points with zero map values become transparent while values above and below zero are colored by shades of blue or red, respectively.
The R2_fromTo array of two elements allows to set the lower and the upper boundaries for the red and blue colors, respectively. All values above and below will be trimmed to the range. For electrostatic maps the array is set to -5.,5. by default.
In the auto mode all grid points are divided to Nof( I_colorTransferFunction ) color classes according to the normalized function value (sigma units around the mean value) and each class is colored as specified in the I_colorTransferFunction (0 means transparent).
If the number of I_colorTransferFunction elements is odd (2* n+1 ) the class boundaries are the following:

  • -infinity
  • Mean- n *sigma,
  • Mean-( n -1)*sigma,
  • Mean-( n -2)*sigma,
  • ...
  • Mean- 1*sigma,
  • Mean
  • Mean+ 1*sigma,
  • ...
  • Mean+( n -1)*sigma,
  • Mean+( n )*sigma.
  • +infinity
For even number of elements (2* n ), boundaries are shifted by half a sigma, so that the middle class is between Mean-0.5*sigma and Mean+0.5*sigma. Color codes are in arbitrary units since the array is normalized so that the highest value corresponds to the red color. Deep blue is 1. Zero is always the transparent color (no coloring). The spectrum is defined in the icm.clr file. Examples of coloring:
  • {0 0 0 0 0,0 0 0 3 10} default map coloring, color only high densities (blue from 3 to 4 Sigma, red >4 Sigma). Comma only shows you where the mean is.
  • {0 1 0} color only Mean+- 0.5*sigma nodes, ignore high and low densities.
  • {1 0 2} color low and high densities by different colors, ignore densities around the mean.
  • {1 2 3 0 5 6 7} similar the previous one, but with more grades
Examples:

read pdb "1crn"
make map potential name="mpot"
color mpot {1 2 0 4 5}
# OR
color mpot


color volume


color volume color_spec

determines the color of the fog in the depthcueing mode ( activated with Ctrl-D ). Format of color_spec is explained here.

For example, if you want that distant parts of you structure are darker (black fog), but the background is sky-blue, you will do the following:

 
color background lightblue   
color volume black  



compare: setting conformation comparison parameters for the montecarlo command


[ Compare atom | Compare variables | Compare surface ]

compare vs_ | as_ [ static | chemical | surface ]

sets a metric for calculating a distance between different conformations in a stack .
The goal of the two following compare commands is to provide a desired setting before the montecarlo command and stack operations. This command defines a filter which is used to decide how many and what conformations from the stochastic optimization trajectory are kept as low energy representatives of a certain area in conformational space. This metric is also used for the subsequent stack manipulations, e.g. compress stack.
The compare command defines the distance measure between molecular conformations which is used to form a set of different low energy conformers in the course of the stochastic global optimization procedure. The defined distance is compared with the vicinity parameter and determines whether two conformations should be considered different or similar (i.e. belonging to the same slot in the conformational stack). The compare command determines the spectrum of conformations that will be retained in the stack, accumulated during a montecarlo procedure. The default comparison set is a set of all free torsion variables (see compare vs_ ). Other methods compare atom RMSD with and without superposition, using chemical superposition, and compare only the atoms in the interface with a molecule ( compare surface ).

Please note that the compare command can change the compareMethod preference.

See also montecarlo, compareMethod.

Compare by deviations of cartesian coordinates with or without superposition


compare [ static ] as_
The command needs to be run when Cartesian root-mean-square deviation for positions of selected atoms ( as_ ) as a distance measure between stack conformations. Set the vicinity parameter to about 2.0 Angstrom if you want to consider conformations deviating by more than 2 A as different conformational families.
By default the selected atoms in different conformations will be optimally superimposed before the coordinate RMSD is calculated. The static option suppresses superposition and measures absolute deviation of the coordinates between conformations. The static option is relevant for ligand atoms in docking simulations to a static receptor.
The result of this procedure is that an internal flag is set to perform cartesian RMSD calculations during montecarlo run, and a set of selected atoms is marked for comparison.



Compare by deviations of internal coordinates/torsions.


compare vs_
use angular root-mean-square deviation for selected internal variables (usually torsion angles) as distance (set vicinity to at least 30.0 degrees accordingly)
Examples:
 
   compare v_//phi,psi            # compare ONLY the backbone angles  
   vicinity=30.0                  # consider two conformations  
                                  # with phi-psi RMSD < 30. as similar  
 
   compare a_2//ca static         # compare Cartesian deviations  
                                  # of the second molecule's alpha-carbon atoms  
                                  # without prior optimal superposition  
   vicinity=3.0                   # consider two conformations with second  
                                  # molecule deviation < 3 A as similar  


Compare by coordinate deviations of the surface patches only


Compare by surface patch rmsd: dynamically selecting comparison atoms

compare surface as_currentObjSelection | as_staticReferenceObject.
Similarly to compare static as_ it will look at absolute deviations of coordinates, but the comparison will be applied dynamically only to a patch subselection of the atoms in the current object in the selectSphereRadius (default 5. A) proximity to the non-current-object atoms of the as_ selection. The selection typically would look like this: a_activeIcmObject.//ca | a_staticPdbReceptorObject.//ca
Example:

 
 compare a_runObj.//ca | a_recName.//ca surface 

Note that this command dynamically calculates a subset of as_currentObjSelection near as_staticReferenceObject . This distance (static RMSD) is used inside montecarlo command or in compress stack .
The surface mode is useful for protein-protein docking simulations when you want to measure the sRmsd distance between the current conformation and the stack conformations ONLY for the interface residues of the moving molecule. The interface residues are dynamically determined as those which are close to the static receptor specified in the second part of the selection. This static receptor should reside in a separate object.
The vicinity size is determined by the selectSphereRadius parameter
An example in which we sRmsd-compare only those carbons of barstar which are next to the barnase surface.
 
 read pdb "1bgs"     # a complex 
 read pdb "1a19.a/"  # the protein ligand only 
 convert  
...     # make maps and other actions to prepare protein-protein docking 
 compare a_//c* | a_1.1 surface  # will use only  
 selectSphereRadius = 7. 
... 
 montecarlo  


compress


[ Compress grob | Compress stack | Compress binary ]

compress grobs or stacks

compress graphical objects


compress g_grobName1 g_grobName2 .. [ r_minimalEdgeLength=.5 ]

compress grob [ selection ] [ r_minimalEdgeLength=.5 ]
simplify a grob (graphical object) by eliminating/merging small triangles into bigger ones. This procedure allows to generate very "low-resolution" molecular surfaces. The default value of the r_minimalEdgeLength is 0.5 Angstroms. Typically compression with the 1. A minimal edge parameter reduces the number of triangles by an order of magnitude. The compression algorithm does not change the connectivity of the surface. Therefore you can still split the compressed grob and find the fully enclosed cavities.
The compress command returns the new number of verteces in i_out and the new number of triangles in r_out variables, respectively (for the last compressed grob only).
Example:

 
read pdb "1crn" 
make grob skin smooth name="g_1crn" # creates a grob with many triangles 
display g_1crn 
compress g_1crn 1. # significantly reduces the number of triangles in the grob
display g_1crn 
compress g_1crn 4. # complete simplifaction of the model
display g_1crn 
It is important in this example to use the make grob skin command with the smooth option, since it closes the cusps.

compress stack of molecular conformations


compress stack [ fast ] [ i_fromConfNumber i_toConfNumber ]

Remove similar and/or high energy conformations from the conformational stack. During a montecarlo run, some conformations of the generated conformational stack may be substituted by newly calculated ones with lower energies. New conformations may violate the initially correct distribution of the conformations in the slots of the stack as defined by the vicinity parameter and by comparison mode specified by the compare command. The compress command compares all the pairs of the stack conformations, identifies pairs of conformations in which two conformations are separated by a distance less than the vicinity threshold, and removes the higher energy stack conformation from each close pair. Optional arguments i_fromConfNumber and i_toConfNumber define a subset of the conformations in the stack which are to be analyzed and compressed (if any). The whole stack (from the first to the last conformations) is processed by default.
Note that if two close conformations are compressed into the better energy one, the number of visits of the resulting conformation will be a sum of the two numbers of visits.
The fast option applies an iterative compression algorithm which can be several orders of magnitude faster but the result may slightly differ form the default compress. The fast algorithm algorithm performs the following steps:

  1. sort conformations by energy
  2. start from the lowest energy conformation
  3. find all conformations with higher energy than the current conformation within vicinity .
  4. delete similar conformations with higher energies and compress stack
  5. move to the next conformation in the new sorted stack, make it current and go back to step 3

See also How to merge and compress several conformational stacks
Example (define a distance and compress) we generate two stacks, merge them and re-compress two sets with a different comparison criterion:
 
 build string "VTLFVALY" 
 mncallsMC = 5000 
 montecarlo   # generates stack, compar 
 write stack "f1" 
 delete stack # clean up and 
 montecarlo   # generates another stack 
 read stack append "f1"  #  
 compare v_/2:5/phi,psi  # compare settings are different 
 vicinity = 40.          #  
 compress stack fast 
 vicinity = 20.          # new vicinity 
 compress stack  


compress files from ICM


compress binary s_inputfile [name=s_gzipfile|delete]

Compresses the s_inputfile file using GZIP algorithm. If the name is specified, the compressed file will be saved as s_gzipfile.If the delete option is specifeid, the compressed file replace the input file. By default .gz extension is added to produce the compressed file name.

connect


[ Connect molcart ]

connect [ append ] [ none ] [ ms_molecule | g_grob ]

connect none

connects selected molecules to the mouse for independent rotation (by the LeftMouseButton) and translation (MiddleMouseButton) with respect to the original coordinate frame.

Option append will add selected molecule to the previously connected molecules
Note, that rotations/translations in the connect mode actually change the atomic coordinates of the selected molecules and keep the coordinate system unchanged in your graphics window.
To restore the usual global mode (i.e. all objects/molecules are disconnected and the mouse does not change their absolute positions, but rather the point of view), hit the Esc key when the cursor is in the graphics window. To restore the global mode temporarily press the Shift button.
Use: connect none to switch back to the global connection Examples:


read pdb "1eff"
copy a_1eff. # create something else in the scene
display ribbon a_*.
connect a_1eff.
# move it around now
connect none # disconnect


Connect to database or database file


NOTE: this functionality is only available in versions 3.6 and above.

connect molcart {S_host_user_pass_db|s_host s_user s_pass s_db} [name=s_connectionID]

Connects to the database server specified by the command parameters. It is possible to also specify the s_connectionID which will be assigned to the connection. Parameters returned by the Name(sql connect) may be used in this command.

connect molcart on

Reconnects to the current Molcart.

connect molcart refresh

Reconnects to Molcart using settings stored in user's preferences.

connect molcart filename=s_file [s_db] [name=s_connectionID]

Opens a Molsoft database file. Database name s_db and the s_connectionID may be specified.

connect molcart s_connectionID off

Disconnects specified Molcart connection. See molcart connection options for explanation

connect molcart local off

Closes all open database files.

See also: molcart, molcart connection options, list molcart, set molcart, Name molcart.

continue


continue

skip commands until the nearest endfor or endwhile .
Example:

 
for i=1,5 
  if i==3 continue  # do not print 3 
  print i 
endfor 

See also: flow control statements.

convert


[ Convert comp | Convert fragments | Convert mol | Convert and reroot ]

convert [ exact ] [ charge ] [graphic] [ tether ] [selection] [auto] [ os_non-ICM-object | as_newRoot ] [ s_newObjectName ]

converts an incomplete non-ICM-object (e.g. object of type 'X-Ray' resulting from the read pdb command) into a true ICM-object for which you may calculate energy, build a molecular surface and perform all operations.
There are two principally dif