Attribute Calculator generates new numerical attributes from existing ones. The calculated attribute values, or even simply the values of an existing attribute, can be written to a file.
There are several ways to start Attribute Calculator, a tool in the Structure Analysis category.
One must specify a name for the attribute to be created and whether it will be an attribute of atoms, residues, or molecules (molecule models). The name must be an alphanumeric string without spaces; it can include underscores, but should not begin with a underscore, digit, or capital letter. Atom attributes with names containing area, volume, or charge (after word separation by camel case and/or underscores) will be totaled automatically to give the corresponding residue attributes.
The Formula is an arithmetic expression. Supported operators are + (addition), – (subtraction), * (multiplication), and / (division). Parentheses can be used for grouping.Terms in the expression can be:
For example, to define a residue (or molecule model) attribute equal to the average B-factor of its constituent atoms:
OK performs the calculation/assignment and dismisses the dialog. Apply performs the calculation/assignment without dismissing the dialog. Close dismisses the dialog, and Help opens this manual page in a browser window.
The formula is not reevaluated automatically; if any constituent attribute values change, OK or Apply must be used again to recalculate the result with the new values.