Top page

Residue graphics commands

In previous versions of MolScript (v1.4 and older), the schematic residue representations could be given only one single colour. In the current version, all residue graphics objects (except cylinder) can be coloured on a residue-by-residue basis. The residue colour is set with the residuecolour parameter. The per-residue colouring mode itself is switched on with the colourparts parameter.

All residue commands operate on chains of residues. All of them, except the double-helix command, define a chain of residues as:

  1. Consisting of amino-acid residues (based on the residue type)
  2. Each residue contains an atom named CA
  3. Consecutive residues in a chain are less than 4.2 Ångström apart.

If a selection of residues given to the residue commands contain breaks in the chain, according to the above criteria, then nothing is output for those chain breaks.

The double-helix command operates on nucleotide residues, so the above criteria are different: The residues must be nucleotides, the required atom name is P, and the maximum distance is 10.0 Ångström. Otherwise this command works in the same way.

This feature simplifies the creation of residue representations when the coordinates contain chain breaks or missing residues. The output from the MolScript program will be sensible without requiring the user to locate each chain break in a coordinate set.

coil residue-selection ;

ras_coil

Create a smooth coil based on the CA atom positions for the given amino-acid residues.

The coil goes through the exact CA positions only at the first and last residues. At least two consecutive CA atoms are needed. The CA coordinates are first copied and smoothed a number of iterations (parameter smoothsteps) using Priestle's algorithm (Priestle 1988). Then a coil with an approximately cylindrical cross-section is created along a curve through the smoothed coordinates. See turn for a variant of coil which does go through every CA position.

The radius of the coil is determined by the parameter coilradius. If the value of the coilradius parameter is lower than 0.01, then a curved line is output, which is affected by the different line parameters. The curvature of the coil can be modulated with the splinefactor parameter.

In the PostScript output mode, the coil radius is affected by the depthcue parameter if the slab has been explicitly set.

The colour is taken from the planecolour parameter if the colourparts parameter is switched off, otherwise the residuecolour is used.

Parameters: coilradius, colourparts, linecolour, linedash, linewidth, planecolour, residuecolour, segments, smoothsteps, splinefactor, lighting.

cylinder residue-selection ;

ras_coil

Create a cylinder representation for an alpha-helix.

The end-points of the cylinder are computed on the assumption that the selected amino-acid residues form a decent alpha-helix. At least three consecutive CA atoms are needed. No cylinder is created for shorter polypeptide chains.

The radius is controlled by the cylinderradius parameter. In the current version of MolScript (v2.1), it is not possible to colour the cylinder on a residue-by-residue basis. The colour is always taken from the planecolour parameter.

In the PostScript output mode, the subdivision of the cylinder into graphical segments is controlled by the segmentsize parameter.

Parameters: cylinderradius, planecolour, segmentsize, lighting.

double-helix residue-selection ;

Create a smooth coil that goes through the P atom positions for the given nucleotide residues.

At least two consecutive P atoms are needed. The same algorithm is used to create this representation as for the amino-acid residue turn. No smoothing of the P atom positions is done. The coil created by this command therefore goes through the exact P positions.

The radius of the turn is determined by the parameter coilradius. If the value of the coilradius parameter is lower than 0.01, then a curved line is output, which is affected by the different line parameters. The curvature of the turn can be modulated with the splinefactor parameter.

The colour is taken from the planecolour parameter if the colourparts parameter is switched off, otherwise the residuecolour is used.

Parameters: coilradius, colourparts, linecolour, linedash, linewidth, planecolour, residuecolour, segments, splinefactor, lighting.

helix residue-selection ;

ras_coil

Create a smooth helical ribbon through the CA atom positions of the given amino-acid residues.

At least three consecutive CA atoms are needed. No helix is created for shorter polypeptide chains. The helix creation algorithm is optimized for regular alpha-helix, but handles common irregularities like proline bends reasonably well. Only the CA atom coordinates are used to compute the helix.

The helixwidth determines the width of the ribbon, which tapers off at the helix terminii to fit the coilradius parameter. Since the helix passes through the CA atom positions, the helix radius cannot be changed.

The colour of the outer surface of the helix is controlled by the planecolour parameter, while the inner surface uses the plane2colour parameter. If the colourparts parameter is switched on, then the inner and outer surfaces of the helix ribbon are given the same colour for each residue, which is then determined by the residuecolour parameter.

In the PostScript output mode, the shading of the helix ribbon is performed as if the axis of the helix had been rotated into the plane of the paper.

In the Raster3D output mode, the helix has a thickness and a rounded edge controlled by the helixthickness parameter.

Parameters: coilradius, colourparts, helixthickness, helixwidth, planecolour, planecolour, residuecolour, segments, lighting.

strand residue-selection ;

ras_coil

Create a beta-strand arrow that goes through the smoothed CA positions of the selected amino-acid residues.

At least three consecutive CA atoms are needed. No strand is created for shorter polypeptide chains.

The smoothing of the CA positions is performed in the same way as for coil, and the parameter smoothsteps applies. The strand will not go through the CA positions except at the ends. Only the CA atom coordinates are used for computing the strand position and normal vectors.

The segments parameter applies, but the actual number of segments created will be (segments / 2) + 1, where the division is integer division. The reason for this is that the curvature for strands is less than for helices, so fewer segments are needed. The strandthickness and strandwidth parameters determine the dimensions of the cross-section of the arrow. If the strandthickness is less than 0.01 Ångström, then an arrow made out of a single surface with no thickness is produced.

The colour of the major strand surface is determined by the planecolour parameter, while the minor strand surface (the arrow side) is controlled by the plane2colour parameter. If the colourparts parameter is switched on, then the major and minor strand surfaces are given the same colour for each residue.

Parameters: coilradius, colourparts, planecolour, planecolour, residuecolour, segments, strandthickness, strandwidth, lighting.

trace residue-selection ;

ras_trace

Draw straight lines between consecutive CA atoms in the polypeptide chain.

The width of the lines is determined by linewidth. The colour is taken from the linecolour parameter if the colourparts parameter is switched off, otherwise from the residuecolour parameter.

Parameters: colourparts, linecolour, linewidth, linedash, depthcue, residuecolour, transparency.

turn residue-selection ;

ras_turn

Create a smooth coil that goes through the CA atom positions for the given amino-acid residues.

The same algorithm is used to create this representation as for coil, except that no smoothing of the CA positions is performed. The coil created by this command therefore goes through all the exact CA positions. At least two consecutive CA atoms are needed.

The radius of the turn is determined by the parameter coilradius. If the value of the coilradius parameter is lower than 0.01, then a curved line is output, which is affected by the different line parameters. The curvature of the turn can be modulated with the splinefactor parameter.

The colour is taken from the planecolour parameter if the colourparts parameter is switched off, otherwise the residuecolour is used.

Parameters: coilradius, colourparts, linecolour, linedash, linewidth, planecolour, residuecolour, segments, splinefactor, lighting.

Top page