Separate programs can control Chimera remotely via tools such as ReadStdin and RESTServer. The following commands are useful for sending information to such programs:
The listen command tells Chimera to start or stop generating notifications when certain events take place; what may be models or selection. Example: listen start models• list models [ spec atom-spec ] [ type model_type ] [ attribute attribute_name ]If what is models, then the events of interest are the addition or removal of a model. Each notification message is prefixed with prefix (default ModelChanged). Typical messages are:
ModelChanged: add model #0 ModelChanged: remove model #0If what is selection, then the event of interest is a change in selected items. Each message is prefixed with prefix (default SelectionChanged). A typical message is:
SelectionChanged: selection changedNormally, notification messages are sent to stdout. If URL is specified, then the messages are sent to the given URL with the message encoded as parameter chimeraNotification.
Report the value of an attribute for models. Information is sent to the Reply Log. By default, the name attribute is reported for all models. If spec is given, only models containing the specified atoms are reported. If type is given, only models with the matching type are reported. Common types include molecule, msmsmodel surfacemodel and vrmlmodel. If attribute is given, the value for attribute_name is reported instead of the model name.• list chains [ spec atom-spec ] [ attribute attribute_name ]
Report the value of an attribute of chains. Information is sent to the Reply Log. By default, the chain attribute is reported for all chains in all molecule models. If spec is given, only chains in models containing the specified atoms are reported. If attribute is given, the value for attribute_name is reported instead of chain.• list physicalchains [ spec atom-spec ]
Report the starting and ending sequence numbers for physically connected chains (no missing residues). Information is sent to the Reply Log. By default, all chains in all molecule models are reported. If spec is given, only chains in models containing the specified atoms are reported.• list residues [ spec atom-spec ] [ attribute attribute_name ]
Report the value of an attribute of residues. Information is sent to the Reply Log. By default, the type attribute is reported for all residues in all molecule models. If spec is given, only residues containing the specified atoms are reported. If attribute is given, the value for attribute_name is reported instead of type.• list atoms [ spec atom-spec ] [ attribute attribute_name ]
Report the value of an attribute of atoms. Information is sent to the Reply Log. By default, the idatmType attribute is reported for all atoms in all molecule models. If spec is given, only the specified atoms are reported. If attribute is given, the value for attribute_name is reported instead of idatmType.• list selection [ level granularity ] [ mode mode ] [ attribute attribute_name ]
Report the value of an attribute for items that are currently selected. Information is sent to the Reply Log. The granularity determines which items are reported. Supported values are atom (default), residue, chain and molecule. The mode may be either any (default) or all. If any, items with any selected subitems are reported; if all, only items whose subitems are all selected are reported. For example, with any a residue of five atoms will be reported if any of the five atoms are selected; with all, all five atoms must be selected for the residue to be reported. If attribute is given, the value for attribute_name is reported instead of the default, which is idatmType for atoms, type for residues, chain for chains, and name for molecules.• list resattr
List the current residue attributes, as would appear in Render/Select by Attribute (some attributes less likely to be relevant to users are suppressed). Information is sent to the Reply Log.• list distmat atom-spec
Report all pairwise distances among the specified atoms. The atom-spec cannot be blank. Information sent to the Reply Log consists of lines that start with “distmat,” followed by the specifiers of the two atoms, followed by the distance in Å. The upper triangle of the distance matrix is given row by row, with atoms in the order (if any) in which they were specified.• sequence atom-spec
Display the Sequence dialog for all chains containing the specified atoms. The atom-spec cannot be blank.