Alignment Header Definition Files

Sequence alignments shown in Multalign Viewer may include header lines. For example, a Conservation line is shown by default.

Arbitrary, user-defined header lines may also be shown. New header contents can be loaded from an external header definition file (Headers... Load in the Multalign Viewer menu), while existing header contents can be saved to the same type of file (Headers... Save in the Multalign Viewer menu). Loading values for a header with the same name as an existing header will create an additional header line, not replace the values in the existing header line.

HEADER DEFINITION FORMAT

A hash symbol # at the beginning of a line indicates a comment. A control line specifies the name of the header:

name: header_name
where header_name is a character string.

An additional, optional control line specifies the type of information:

style: data_type
where data_type can be character or numeric. Characters (a single character per position) will be displayed directly in the header line, while numeric values will be shown as histogram bars.

Header values are given in data lines of the form:

(Tab)alignment_pos(Tab)header-value(Tab)color
where alignment_pos is a position in the alignment (an integer). Data lines can be in any order, and not every position in the alignment must be represented in the file. Positions with no value will be blank in the header line. Control lines and comments can be interspersed with data lines. However, if multiple headers are defined in the same file, the name control line should precede all other lines for the corresponding header.

The style governs whether header-value must be a single character or a number. If the style is not specified, it will be assumed to be character if the header_value in the first data line is a single character; otherwise, it will be assumed to be numeric. The range of numeric values is assessed after the file is read. If the values range from 0 to 1, they will be used directly as histogram bar heights. If the range extends below 0 or above 1, the values will be converted into histogram bar heights ranging from 0 to 1 according to:

for values ≥ 0,    1 – ½(e–value)
for values < 0,    ½(evalue)
However, the original values (not those used for histogram display) are used for residue attributes and written out when header contents are saved.

The color is optional but can be specified as either of the following:

A single header definition file can incorporate both kinds of color specifications, as well as lines without color specifications. Default colors are used for data without color specifications: black for character values, dark gray for numeric values (which will be shown with histogram bars).


UCSF Computer Graphics Laboratory / September 2005