14.2 Standard commands

These are the VEGA standard commands:

 

ADDHYDROG    (MCHAR)MolType   (MCHAR)HPos   (BOOL)IupacNames   (BOOL)ActiveOnly
Add the hydrogens to the molecule. If the hydrogens are already present, they will be removed before the adding procedure.

Parameters:
MolType   

Molecule type. It must be GEN (generic organic), GENBO (generic organic, bond order method), NA (nucleic acid), NABO (nucleic acid, bond order method), PROT (protein) and PROTBO (protein, bond order method). Use the bond order method if the molecule has a 2D/3D structure  having bonds with specified order (e.g. single, partial double, double, triple). The standard method doesn't work properly if the molecule structure is distorted or it have two dimensions only.

HPos

Hydrogen position in the file. It must be HEAVYATM (the hydrogens are placed after each heavy atom) or RESEND (the hydrogens are placed at the end of each residue).

IupacNames

If it's true (1), IUPAC hydrogens name convention is used.

ActiveOnly

If it's true (1), the hydrogens are added to active (visible) atom only.

Return values:
The number of added hydrogens.

Example:
ADDHYDROG   GEN   RESEND   1   0

See also:
ADDIONS.


ADDIONS    (CHAR)Element   (INT)Charge   (UINT)Ions   (FLOAT)ExclAtomRad   (FLOAT)ExclIonRad   (FLOAT)GridStep   (FLOAT)BoxThick
With this command is possible to add one or more counter ions to the active molecule. For more information about the method, please click here.

Parameters:
Element   

Counter ion element (e.g. Na, K, Mg, Cl, etc).

Charge

Ion charge (e.g. 1, 2, -1, etc).

Ions

Number of ions to add.

ExclAtomRad

Atom-ion closest distance.

ExclIonRad

Ion/ion closest distance in order to reduce the electrostatic repulsion.

GridStep

Grid step to build the grid used to place the ions.

BoxThick

Box thickness surrounding the molecule.

Return values:
Error code if it fails.

Example:
ADDIONS   Na   1   5   6.5   11   0.5   10

See also:
ADDHYDROG.


ASSINGBNDORD    (BOOL)ActiveOnly
Assign the bond order (single, partial double, double and triple).

Parameters:
ActiveOnly   

If it's true (1), the command assigns the bond order to active atoms only.

Return values:
Error code if it fails.

Example:
ASSIGNBNDORD   0

See also:
CONNBUILD, CONNDESTROY.


ATMADD
Add a new atom to the current workspace. The atom is placed at (0, 0, 0) coordinates, the default element is the carbon (C), the atom  name is C, the residue name is UNK, the residue number is 1, the atom charge is 0, the atom type is ?, the color is green. To change these default properties see the ATMSETcommand.

Parameters:
None.

Return values:
If the command fails, 0 is returned, otherwise the atom number is returned.

Example:
ATMADD

See also:
ATMBEGINUPDATE, ATMBOND, ATMDELETE, ATMGET, ATMSET, ATMENDUPDATE.


ATMBEGINUPDATE
Notify a massive atom update to the system. This command increase the performance of the subsequent atom commands.

Parameters:
None.

Return values:
Error code if it fails.

Example:
ATMBEGINUPDATE

See also:
ATMADD, ATMGET, ATMSET, ATMENDUPDATE.


ATMBOND   (UINT)AtomNumber1   (UINT)AtmNumber2   (MCHAR)BondOrder
Bond/unbond two atoms or change the bond order.

Parameters:
AtomNumber1   

Number of the first atom.

AtomNumber2

Number of the second atom.

BondOrder

The bond order could be: NONE (unlink the two atoms), SINGLE, PARDOUBLE (partial double bond, aromatic), DOUBLE and TRIPLE.

Return values:
If the command fails, 0 (false) is returned, otherwise 1 (true) is returned.

Example:
ATMBOND   1   7   NONE
ATMBOND   4   9   SINGLE
ATMBOND   4   9   DOUBLE

See also:
ATMBEGINUPDATE, ATMADD, ATMGET, ATMENDUPDATE, ATMSET.


ATMDELETE   (UINT)AtomNumber   (UINT)AtomsToDelete
Delete one or more atoms. The undeleted atom identification number is automatically renumbered and so the atom IDs could be be the same before the deletion.

Parameters:
AtomNumber   

Number of the first atom to delete.

AtomsToDelete

Total number of atoms to delete.

Return values:
The command returns the number of deleted atoms.

Example:
ATMDELETE   12   1
ATMDELETE   24   9

See also:
ATMBEGINUPDATE, ATMADD, ATMENDUPDATE.


ATMENDUPDATE
Notify the end of the atom update.

Parameters:
None.

Return values:
Error code if it fails.

Example:
ATMENDUPDATE

See also:
ATMBEGINUPDATE, ATMADD, ATMGET, ATMSET.


ATMFIND   (MCHAR)Mode   (UINT)FirstAtom   (CHAR)String
Find an atom by element, atom name and atom type.

Parameters:
Mode   

Search mode: ELEM for atom element, NAME for atom name and ATMTYP for atom type.

FirstAtom

The first atom from which the search starts.

String

String to find. It could be: atom element (1 one or two characters, case insensitive), selection string (in standard VEGA ZZ format with/without wildcards), and atom type. The atom type search can be used only if the force field is applied to the molecule (see FORCEFIELD).

Return values:
The command returns the atom number of the first atom that satisfy the search criteria. If no atom is found, 0 is returned.

Example:
ATMFIND   ELEM   1   N
ATMFIND   NAME   1   C1
ATMFIND   NAME   25   CA:ALA
ATMFIND   NAME   1   N*:VAL:*:*:1
ATMFIND   ATMTYP 1 cp

See also:
ATMGET.


ATMGET   (UINT)AtomNumber    (MCHAR)Property
Get a property of the specified atom number.

Parameters:
AtomNumber   

Atom number.

Property

Atom property to obtain.

  
Property Type Value range Size Description
Active BOOL 0-1 1

It it's true (1), the atom is active (visibile), otherwise the atom is inactive (invisible).

Chain CHAR - 1

Chain ID.

Color CHAR - 1-2

Atom color (see COLOR for the color names).

Connect CHAR - 0-6 words

It's a string containing from 0 to 6 number corresponding to the connected atoms. If no atoms are connected, an empty string is returned.

Coord CHAR - 3 words

It's a string containing the three atom coordinates in floating point format.

DrawMode UINT 0-9 1

Atom draw mode. It can be:

DrawMode Description
0 Wireframe.
1 CPK/Van der Waals dotted.
2 CPK/Van der Waals wireframe.
3 CPK/Van der Waals solid.
4 Ball & stick wireframe.
5 Ball & stick solid.
6 Stick wireframe.
7 Stick solid.
8 Tube solid.
9 Trace solid.
Elem CHAR - 1-2

Atom element.

Fix FLOAT - -

Atom constraint value for MD. For more information, click here.

Flags INT - -

Atom flags. They can be combined with OR operator or addition.

Value Description
0 None.
1 HETATM flag.
2 The atom is the last one in the segment.
4 The atom is the last one in the molecule.
8 The atom is a centroid.
16 The atom is a fixed centroid.
32 It's an organic atom.
64 The atom will not considered in the MD trajectory analysis.
Label UINT 0-10 1-2

Label shown. It can be:

Value Description
0 None
1 Atom name
2 Element
3 Atom number
4 Atom type
5 Charge
6 Chirality
7 Constraint value
8 Residue name & number
9 Residue name
10 Residue number
Name CHAR - 1-4

Atom name.

NSost UINT 0-6 1 Number of bonded atoms.

ResName CHAR - 1-4

Residue name.

ResSeq CHAR - 1-4

Residue number.

Type CHAR - 1-8

Atom type (force field).

Return values:
The requested atom property or an error if it fails.

Example:
ATMGET   12   COORD

See also:
ATMBEGINUPDATE, ATMADD, ATMFIND, ATMSET, ATMENDUPDATE.


ATMSET   (UINT)AtomNumber    (MCHAR)Property    (CHAR)Value
Set a property of the specified atom number.

>Parameters:
AtomNumber   

Atom number.

Property

Atom property to obtain. For the property list see the ATMGET command but remember that Connect and NSost are read-only properties and can't be changed with this command.

Value

New property value.

Return values:
Error code if it fails.

Example:
ATMSET   30   COLOR   GREEN

See also:
ATMBEGINUPDATE, ATMADD, ATMGET, ATMFIND, ATMENDUPDATE.


CHDIR   (CHAR)Directory
Change the current directory. Use CURDIR variable to get it.

Parameters:
Directory   

New directory path.

Return values:
Error code if it fails.

Example:
CHDIR   "C:\My Documents\Molecules"

See also:
None.


CHARGE   (CHAR)Method   (BOOL)ActiveOnly
Assign the atomic partial charges using the specified method.  For more information, click here.

Parameters:
Method   

Method to assign the atomic partial charges. You can choose the Gasteiger-Marsili (Gasteiger keyword) method or the fragment/residue based on a pre-computed database of charges (Charmm22_Char or other keywords).

ActiveOnl

If it's true (1), the force field is assigned only to the active (visible) atoms. If it's false (0), the force field is assigned to all atoms (visible an invisible).

Return values:
Error code if it fails.

Example:
CHARGE    Gasteiger   0
CHARGE    Charmm22_Char   1

See also:
FORCEFIELD, mCalcCharge.


CONNBUILD   (UINT)Overlap    (BOOL)ActiveOnly
Build the connectivity.

Parameters::
Overlap

Overlapping percentage of covalent radii to consider two bonded atoms. The usual value is 20.

ActiveOnly   

If it's true (1), the command calculates the connectivity to active atoms only.

Return values:
Error code if it fails.

Example:
CONNBUILD   20   0

See also:
ASSIGNBNDORD, CONNDESTROY.


CONNDESTROY   (BOOL)ActiveOnly
Destroy the connectivity.

Parameters:
ActiveOnly   

If it's true (1), the command removes the connectivity to active atoms only.

Return values:
Error code if it fails.

Example:
CONNDESTROY   1

See also:
ASSIGNBNDORD, CONNBUILD.


CPUFINDFILE   (CHAR)FileName
Check if the specified executable or DLL file exists and return a new file name if an executable with better performances is present. 

Parameters:
FileName   

Method to assign the atomic partial charges. At the present time, the only supported method is Gasteiger.

Return values:
An empty string if the file doesn't exist or the executable file name optimized for the installed CPU.

Example:
CPUFINDFILE    BioDock.exe
If your system has got an AMD Athlon and the specific executable is installed, the command returns BioDock_k7.exe.

See also:
None.


ENEPARGET   (CHAR)ParameterKey    (BOOL)DefaultValue
Get a parameter used for the molecular mechanics energy evaluation.

Parameters::
ParameterKey   

Name of the parameter.

DefaultValue

If it's true (1), the default value is returned, otherwise if it's false (0), the current value is returned.

Return values:
The value associated to the parameter key.

Example:
ENEPARGET    AEXP   0

See also:
ENEPARSET.


ENEPARSET   (CHAR)ParameterKey    (CHAR)NewValue
Set a parameter used for the molecular mechanics energy evaluation.

Parameters:
ParameterKey   

Name of the parameter.

NewValue  

New parameter value. It can be an integer or a floating point number.

Return values:
Error code if it fails.

Example:
ENEPARSET    AEXP   4

See also:
ENEPARGET.


ERRMSG   (UINT)ErrorCode
Return the error description (standard C format) from the error code.

Parameters:
ErrorCode   

Error code.

Return values:
Error string.

Example:
ERRMSG    201

See also:
MSGERRMODE.


FIXAROM   (BOOL)ActiveOnly
Fix the aromatic rings replacing the conjugated bonds with partial double bonds.

Parameters:
ActiveOnly  

If it's true (1), the active (visible) bonds only are fixed. If it's false (0), all bonds are fixed.

Return values:
The command returns the number of atoms involved in the bond fixing. Dividing by two this value, you obtain the number of changed bonds.

Example:
FIXAROM    0

See also:
None.


FORCEFIELD   (CHAR)Template    (BOOL)ActiveOnly   (BOOL)Quiet
Assign the atom types using the specified template. For more information, click here.

Parameters:
Template   

Template name used to assign the atom types.

ActiveOnly

If it's true (1), the force field is assigned only to the active (visible) atoms. If it's false (0), the force field is assigned to all atoms (visible and invisible).

Quiet

If it's true, no warning messages are shown if a problem was found during the force field attribution.

Return values:
Error code if it fails.

Example:
FORCEFIELD    CVFF   0   1

See also:
CHARGE, mCalcCharge.


GET   (CHAR)Variable
The command GET returns the value of a specific internal variable. The argument name is case-insensitive and the returned value is always a character string. The result can be read from clipboard or from Result item of VGP_VEGAINFO structure if the command is sent by a plug-in (see plugin.h). SendVegaCmd retrieves the result automatically from the clipboard.
If you call the GET command from a plug-in, please use  PLUGINGET instead of it.

Standard variables:

Variable Type Description
CPUFEATURES INT

32 bit integer containing the CPU features (for x86 CPUs only).

CPUNAME CHAR

Installed CPU name.

CPUS UINT

Number of the installed CPUs.

CPUTYPE CHAR

Type, family, model and stepping of the installed CPU (for x86 CPUs only).

CPUVENDOR CHAR

CPU vendor.

CURDIR CHAR

Current directory.

CURLANG CHAR

Current language for string translation.

DATADIR CHAR

Full path of data files (e.g. templates, preferences, etc).

ERRCODE UINT

Last error code.

ERRSTR CHAR

Last error string.

FLEXTOR UINT

Number of flexible torsions.

FORMULA CHAR

Molecular formula.

GCMR FLOAT Ghose and Crippen molar refractivity. If an error occurs, an empty value is reported.
HBACC UINT Number of H-bond acceptor atoms (N and O only).
HBDON UINT Number of H-bond donor atoms (H-N and H-O only).
INCHI CHAR

IUPAC InChI string.

INCHIAUX CHAR

IUPAC InChI string + auxiliary data.

LASTFILENAME CHAR

Name of the last loaded file without path and extension.

MASS FLOAT

Mass of the molecule in Daltons.

OS CHAR

Operating system (e.g. AmigaOS, Linux, Irix, Unix, Windows 95/98/ME, Windows NT/2000/XP/Vista).

OSFAMILY CHAR

Operating system family (e.g. amigaos, unix, windows).

PRFLANG CHAR

Language for string translation in prefs file.

SAVEDIR CHAR

Default path for save operations.

SEQUENCE CHAR

Amino/nucleic acid sequence.

SRFCUR UINT

Current surface number.

SRFNAME CHAR

Name of the current surface.

SRFTYPE UINT

Current surface type (0 = dotted/unknown, 1 = mesh, 2 = solid).

TMPDIR CHAR

Temporary directory.

TMPFILE CHAR

Full path and file name to use as temporary file.

TOTACTATM UINT

Total number of active (visible) atoms.

TOTANG UINT

Total number of angles.

TOTATM UINT

Total number of atoms of the current loaded molecule.

TOTBOND UINT

Total number of bonds.

TOTCHAIN UINT

Total number of chains.

TOTCHIRAL UINT

Total number of chiral centres.

TOTEZ UINT

Total number of bonds with E/Z geometry.

TOTHEAVYATM UINT Total number of heavy atoms.
TOTHYDROG UINT Total number of hydrogens.
TOTIMP UINT

Total number of improper angles.

TOTMOL UINT

Total number of molecules. It doesn't perform any seek to find the molecules, but counts the end-of-molecule tags in the atom list. If these tags are missing or misplaced, the number of molecules could be wrong.

TOTREALMOL UINT

Real number of the molecules. It performs the seek to find the molecules, returning the real number of molecules.

TOTRES UINT

Total number of residues.

TOTRING UINT Total number of rings.
TOTSEG UINT

Total number of segments.

TOTSRF UINT

Total number of surfaces.

TOTSRFDOT UINT

Total number of the current surface dots.

TOTSRFTRI UINT

Total number of the current surface triangles.

TOTTOR UINT

Total number of torsion angles.

TRJBESTENERGY FLOAT

The energy of the best frame in the trajectory file.

TRJBESTFRM UINT

The number of the best frame.

TRJCURFRM UINT

The current frame number selected in the trajectory.

TRJSIMTIME UINT

Length (in ps) of the simulation.

TRJSTARTTIME UINT

Start time (ps) of the simulation.

TRJTEMP UINT

Simulation temperature (Kelvin).

TRJTIMESTEP UINT

Time step.

TRJTOTFRM UINT

Total number of frames in the trajectory.

TRJWORSEENERGY FLOAT

The energy of the worse frame in the trajectory file.

TRJWORSEFRM UINT

The number of the worse frame.

VEGADIR CHAR

Directory path where VEGA is installed.

VERSION CHAR

Full VEGA version.

VLOGP FLOAT Virtual logP. If an error occurs, an empty value is reported.

OpenGL variables:

Variable Type Description
BACKCOLOR UINT

Background color in RGB format.

CONBUFSIZE UINT

Console buffer size (lines).

CONDOCKED BOOL

True if the console is docked.

CONHISTSIZE UINT

Max. number of commands stored in the history buffer.

CONPOSX UINT

X screen position of the console window. If the console is docked, the return value is 0.

CONPOSY UINT

Y screen position of the console window. If the console is docked, the return value is 0.

CONSIZEX UINT

Width of the console window.

CONSIZEY UINT

Height of the console window.

CONVISIBLE BOOL

True if the console is open.

GLASSWIN BOOL

True if the glass windows are enabled.

GLRENDERER CHAR

OpenGL rendering subsystem (hardware/software).

GLVENDOR CHAR

The vendor of the graphic card.

GLVERSION CHAR

OpenGL subsystem version.

GRAPHID UINT

The ID of the current Graph Editor window

GRAPHLABELX CHAR

X axis label.

GRAPHLABELY CHAR

Y axis label.

GRAPHPOINTS UINT

Number of the points in the current graph.

GRAPHPOSX UINT

X screen position of the Graph Editor window.

GRAPHPOSY UINT

Y screen position of the Graph Editor window.

GRAPHSIZEX UINT

Width of the Graph Editor window.

GRAPHSIZEY UINT

Height of the Graph Editor window.

GRAPHTITLE CHAR

Chart title.

GRAPHVISIBLE BOOL

True if the Graph Editor is open (obsolete, only for backwards compatibility.

ISRUNNING BOOL

True if a background calculation is running (e.g. Mopac).

LIGHT BOOL

True if the light is enabled.

LIGHTAMB BOOL

True if the ambient light is enabled.

LIGHTAMBCOLOR UINT

Ambient light color.

LIGHTCUR UINT

Number of the current light source (from 0 to 3).

LIGHTCURDIFCOL UINT

Diffuse color of the current light source.

LIGHTCUREN BOOL

True if the current light source is enabled.

LIGHTCURSPECCOL UINT

Specular color of the current light source.

LIGHTCURPOS CHAR

Position of the current light source. It's a string containing a vector (X, Y, Z coordinates).

LOGOPOS UINT

Position of the VEGA ZZ superimposed logo:

Value Position
0 Logo disabled
1 Top left
2 Top center
3 Top right
4 Center left
5 Centered
6 Center right
7 Bottom left
8 Bottom center
9 Bottom right
LOGOSCALE FLOAT

Scale factor of the VEGA ZZ superimposed logo (default 0.5).

MAINSIZEX UINT

Width of the main window.

MAINSIZEY UINT

Height of the main window.

MAINPOSX UINT

X screen position of the main window.

MAINPOSY UINT

Y screen position of the main window.

MATSHINY UINT

Material shininess.

MATSPECULAR UINT

Material specularity.

MATVECTSPEC BOOL

True if the vector specularity is enabled.

MSAA UINT

Current multisample anti-aliasing value (0-16x, 0 = disabled).

PORTNUM UINT

Communication port number.

ROTX FLOAT

X rotation of the scene (degree).

ROTY FLOAT

Y rotation of the scene (degree).

ROTZ FLOAT

Z rotation of the scene (degree).

SCALE FLOAT

Visualization scale.

SCREENDEPTH UINT

Screen depth in bit per pixel.

SCREENX UINT

Screen width.

SCREENY UINT

Screen height.

SKYBOXENABLED BOOL

True if the SkyBox/SkyVision is enabled.

SKYBOXNAME CHAR

Name of the current SkyBox.

SKYBOXOFFSETX FLOAT

SkyBox X offset.

SKYBOXOFFSETY FLOAT

SkyBox Y offset.

SKYBOXROTX FLOAT

SkyBox X rotation (degree).

SKYBOXROTY FLOAT

SkyBox Y rotation (degree).

SKYBOXROTZ FLOAT

SkyBox Z rotation (degree).

SOUNDEFFECTS BOOL

True if the sound effects are enabled.

SRFALPHA BOOL

Check if the current surface alpha blending  is active (1) or not (0).

SRFALPHAVAL UINT

Alpha value of the current surface (from 0 to 255).

SRFDOTSIZE UINT

Dot size of the current surface used for the visualization (from 1 to 10). It returns 0 if no surfaces are available.

SRFVISIBLE BOOL

Check if the current surface is visible (1) or not (0).

TOTCTOR UINT

Total number of torsions angles usable for a calculation.

TRANSX FLOAT

X translation of the scene.

TRANSY FLOAT

Y translation of the scene.

TRANSZ FLOAT

Z translation of the scene.

WINHANDLE UINT

Main window handle.

WKSCURNUM UINT

Progressive number of the current workspace. 0 is the main workspace and it's always present.

WKSCURNAME CHAR

Name of the current workspace.

WKSTOT UINT

Number of the workspaces. It's at least greater or equal to 1.

Return values:
The value of the specified variable.

Example:
GET   TOTATM

See also:
PLUGINGET.


MERGE   (CHAR)FileName   (INT)Flags   (BOOL)ActiveOnly   (BOOL)Force
Merge the loaded molecule with one or more parts of another molecule. For more information click here.

Parameters:
FileName   

File name of the object to load (molecule, surface, trajectory).

Flags

This argument allows to specify the molecule fields/elements that are merged with the atoms already in memory. The following values can be combined through the "or" operator (or addition):

   
Value Description
1 Atom charges
2 Atom names
4 Atom types
8 Chain IDs
16 Connectivity
32 Atom constraints
64 Atomic coordinates
128 Atom elements
256 Molecule IDs
512 Residue names
1024 Residue numbers
2048 Segments
  
ActiveOnly

If it's true (1), it merges the molecule with the active (visible) atoms only, otherwise (false, 0) it merges the molecule with all atoms in memory.

Force

If it's true (1) and the molecules are different (but with the same number of atoms), the merging is forced.

Return values:
Error code if it fails.

Example:
MERGE     "C:\Documents\Molecules\MyMolecule.pdb"   10   0

See also:
NEW, SAVE, mMerge, mNew, mOpen, mSave.


MSGERRMODE   (MCHAR)Mode
This command sets the mode used by VEGA to show the error messages.

Parameters:
Mode   

Error message mode. It can be:

Console

Shows the errors in the console window (default for command line operation mode).

Quiet

No errors are shown.

Window

All errors are shown in a standard request window (default for OpenGL operation mode).

Return values:
Error code if it fails.

Example:
MSGERRMODE     Console

See also:
ERRMSG.


NEW
It cleans all objects, removing molecules, surfaces, selections, etc from the memory, without confirm. Use mNew if you want that this operation must be confirmed.

Parameters:
None.

Return values:
Error code if it fails.

Example:
NEW

See also:
OPEN, MERGE, SAVE, mNew, mOpen, mSave.


OPEN   (CHAR)FileName
Open a molecule or  a surface or a trajectory file.

Parameters:
FileName   

File name of the object to load (molecule, surface, trajectory).

Return values:
Error code if it fails.

Example:
OPEN     "C:\Documents\Molecules\MyMolecule.pdb"

See also:
MERGE, NEW, SAVE, mMerge, mNew, mOpen, mSave.


REMATOMS   (CHAR)Selection
Remove one or more atoms using the pattern matching.

Parameters:
Selection   

It's the atom selection in standard VEGA format. For more information, see the SELECT command. Please remember that if you want remove a single atom, you can put the atom number only instead of the standard string selection.

Return values:
The number of the removed atoms.

Example:
REMATOMS     *:HOH

See also:
SELECT, mRemoveHydrog, mRemoveInvisAtm, mRemoveWater.


SAVE   (CHAR)FileName   (CHAR)Format  (CHAR)Compression  (BOOL)Flags
This command saves the current molecule or assembly.

Parameters:
FileName   

File name of the output molecule (the file extension is added automatically if not present).

Format

File format (see -f command line option).

Compression

Compression mode (NONE, BZIP2, GZIP, POWERPACKER, ZCOMPRESS).

Flags

Special flags that can be combined through the OR logical operator (or addition):

  
Flag Description
1

Save the connectivity.

2

Save the constraints if the file format supports them.

4

Don't update the last saved file list in the File menu (VEGA ZZ only).

8

Big endian number format. This flag is supported by the IFF format only.

16

64 bit. Enable the 64 bit subformat saving the IFF files.

Return values:
Error code if it fails.

Example:
SAVE    MyMolecule.pdb   PDB    BZIP2   1

See also:
MERGE, NEW, OPEN, mMerge, mNew, mOpen, mSave.


SRFCALC   (MCHAR)SurfaceVis   (MCHAR)SurfaceType    (UFLOAT)ProbeRadius   (UINT/UFLOAT)Density/MeshSize (BOOL)SelectedOnly
Calculate and show (in OpenGL mode) the molecular surface.  The MLP, MEP and ILM calculations ignore the ProbeRadius. Please remember that the last calculated surface becomes the current.

Parameters:
SurfaceVis

Surface visualization mode (DOTS, MESH, SOLID).

SurfaceType   

Surface type (DEEP, HBACC, HBDON, ILM, MEP, MLP, PSA and VDW).

ProbeRadius

Probe radius in Å.

Density/MeshSize

Dot density in Ų for dotted surface or mesh size for mesh and solid surface.

SelectedOnly

If it's true (1), the visible atoms only will be considered, otherwise if it's false (0), the the surface is calculated for all atoms.

Return values:
The command returns the total surface area in Ų, the surface diameter in Å, the minimum, the maximum, the average value and its standard deviation of the calculated property. If the SurfaceType is MLP, it returns the Virtual LogP value also, if the SurfaceType is PSA and it returns the positive and the negative surface areas in Ų.
If it fails, the error code is returned.

Example:
SRFCALC   SOLID   PSA   1.4   1.0   0

See also:
OPEN, SRFSAVE, mOpen, mSurface.


SRFCUR   (UINT)SurfaceID 
It makes current the specified surface.

Parameters:
SurfaceID

Surface identification number (1 for the first, 2 for the second and so on).

Return values:
Error code if it fails.

Example:
SRFSETCUR   2

See also:
OPEN, SRFCALC, SRFCOLOR, SRFCOLORBY, mOpen, mSurface.


SRFREMOVE
It removes the current surfaces from the current workspace. The current surface is set to the next surface in the surface list, but if the removed surface is the last, the it's set to the previous.

Parameters:
None.

Return values:
Error code if it fails.

Example:
SRFREMOVE

See also:
OPEN, SRFCUR, SRFREMOVEALL, SRFCALC.


SRFREMOVEALL
This command removes all surfaces from the current workspace. The surfaces in the other workspaces are kept.

Parameters:
None.

Return values:
Error code if it fails.

Example:
SRFREMOVEALL

See also:
OPEN, SRFREMOVE, SRFCALC.


SRFSAVE   (CHAR)FileName   (UINT)SurfaceID   (MCHAR)Format   (CHAR)Compression
This command saves the surface.

Parameters:
FileName   

Output file name (the file extension is added automatically if not present).

SurfaceID

Surface identification number (0 for the first, 1 for the second and so on).

Format

Surface format (CSV, INSIGHT, QUANTA, Raw, VrmlDotted, VrmlSolid).

Compression

Compression mode (NONE, BZIP2, GZIP, POWERPACKER, ZCOMPRESS).

Return values:
Error code if it fails.

Example:
SRFSAVE   "Molecules\MySurface"   0   QUANTA   NONE

See also:
OPEN, SRFCALC, SRFCOLOR, SRFCOLORBY, mOpen, mSurface.


TRJCLOSE   (UINT)Handle
Close a trajectory stream and release its resources.

Parameters:
Handle   

It's the trajectory stream handle returned by the TrjCreate command.

Return values:
If it fails (e.g. the stream is already closed or the handle is invalid), 0 (false) is returned, otherwise 1 (true) is set.

Example:
TRJCLOSE   23567

See also:
TRJCREATE, TRJWRITE.


TRJCREATE   (CHAR)FileName    (MCHAR)Format    (UINT)Compression   (INT)Flags   
Create a new trajectory stream.

Parameters:
FileName   

File name of the MD trajectory to create.

Format

The trajectory file format. It should be: DCD (NAMD/CHARMM DCD), IFF, MOL2 (Sybyl Mol2 multi model), PDB (PDB multi model), TRR (Gromacs TRR) and XTC (Gromacs XTC compressed trajectory).

Compression

This argument has effect with the XTC format only and it's the floating point precision used in the XDRF compression. The allowed values are from 1 to 6. For more information about it, click here.

Flags

Control flags that can be combined with the "or" operator (or addition):

  
Flag Value Description
TRJSAVE_ACTONLY 1

Save the active/visible atoms only.

TRJSAVE_SWAPEND 2

Swap the endian. Only for DCD files. For more information click here.

TRJSAVE_APPEND 4

Append the trajectory to another merging them each other.

Return values:
If no errors are found, the handle is returned, otherwise the function returns 0.

Example:
TRJCREATE    "C:\Temp\mytrajectory.dcd"  XTC  4  0

See also:
TRJCLOSE, TRJWRITE.


TRJOPEN   (CHAR)FileName    (BOOL)OpenDialog
Open a trajectory file to analyze it.

Parameters:
FileName    Trajectory file to analyze.
OpenDialog

If 1 (true), the analysis dialog box is open.

Return values:
Error code if it fails.

Example:
TRJOPEN    "Simul.DCD" 1

See also:
OPEN, TRJSAVE, TRJSEL, TRJSELFIRST, TRJSELLAST, TRJSELLAST, mOpen, mSaveTraj, mAnalysis.


TRJSAVE   (CHAR)FileName    (MCHAR)Format   (UINT)StartFrm   (UINT)EndFrm   (UINT)SkipFrm   (INT)Flags   (UINT)Compression
Save the current MD trajectory converting it in the specified format.

Parameters:
FileName   

File name of the MD trajectory to save.

Format

The trajectory file format. It should be: DCD (NAMD/CHARMM DCD), PDB (PDB multi model) TRR (Gromacs TRR) and XTC (Gromacs XTC compressed trajectory).

StarFrm

Starting frame number.

EndFrm

Ending frame number. To obtain the total number of trajectory frames, use GET TRJTOTFRM.

>SkipFrm

The number of frame to skip. Use 0 to skip nothing.

Flags Control flags that can be combined with the "or" operator (or addition):
  
Flag Value Description
TRJSAVE_ACTONLY 1

Save the active/visible atoms only.

TRJSAVE_SWAPEND 2

Swap the endian. Only for DCD files. For more information click here.

TRJSAVE_APPEND 4

Append the trajectory to another merging them each other.

  
Compression

This argument has effect with the XTC format only and it's the floating point precision used in the XDRF compression. The allowed values are from 1 to 6. For more information about it, click here

Return values:
Error code if it fails.

Example:
TRJSAVE    "C:\Temp\mytrajectory.dcd"  DCD  1  100  0  0  1

See also:
OPEN, TRJOPEN, mOpen, mSaveTraj, mAnalysis.


TRJSEL   (UINT)Number
Select the frame by number. The trajectory must be opened with TRJOPEN command.

Parameters:
Number   

Frame number .(0 < Number <= LastFrameNumber)

Return values:
Error code if it fails.

Example:
TRJSEL    25

See also:
OPEN, TRJOPEN, TRJSELFIRST, TRJSELLAST, TRJSELLAST, mOpen, mAnalysis.


TRJSELFIRST
Select the first frame of the trajectory. The trajectory must be opened with TRJOPEN command.

Parameters:
None.

Return values:
Error code if it fails.

Example:
TRJSELFIRST

See also:
OPEN, TRJOPEN, TRJSEL, TRJSELLAST, TRJSELLAST, mOpen, mAnalysis.


TRJSELLAST
Select the last frame of the trajectory. The trajectory must be opened with TRJOPEN command.

Parameters:
None.

Return values:
Error code if it fails.

Example:
TRJSELFIRST

See also:
OPEN, TRJOPEN, TRJSEL, TRJSELFIRST, mOpen, mAnalysis.


TRJWRITE   (UINT)Handle
Write the current conformation into a trajectory stream.

Parameters:
Handle   

It's the trajectory stream handle returned by the TrjCreate command.

Return values:
If it fails, 0 (false) is returned, otherwise 1 (true) is set.

Example:
TRJWRITE   23567

See also:
TRJCREATE, TRJCLOSE.


VOLUME   (UINT)Density   (BOOL)SelectedOnly
Calculate the molecular volume.

Parameters:
Density   

Dot density in Ų for the grid calculation. Greater values mean more precise calculation.

SelectedOnly

If it's true (1), the visible atoms only will be considered.

Return values:
The command returns the volume in Å3 and the volume diameter in Å.

Example:
VOLUME   20   0

See also:
SRFCALC.


Back to the command index