Interface Structure

A single atomic structure

interface Structure {
    bonds?: [number, number, number][];
    cell?: number[];
    chains?: string[];
    elements?: string[];
    hetatom?: boolean[];
    names: string[];
    resids?: number[];
    resnames?: string[];
    shapes?: {
        [name: string]: ShapeParameters;
    };
    size: number;
    x: number[];
    y: number[];
    z: number[];
}

Properties

bonds?: [number, number, number][]

bonds in structures given as [i, j, order], where i, j, and order are integers. i and j are the indices of the atoms bonded together, and order is the bond order, which can be 1 (for single bonds) or 2 (for double bonds) or 3 (for triple bonds)

cell?: number[]

Unit cell of the system, given as [ax ay az bx by bz cx cy cz], where a, b, and c are the unit cell vectors. All values should be expressed in Angströms.

chains?: string[]

Chain names of all atoms in the structure, if available. This is only used for secondary structure assignment.

elements?: string[]

Element names of all atoms in the structure, if available

hetatom?: boolean[]

Wether an atom is a heteroatom, i.e. not part of a biomolecule (protein, dna, …). If this is not provided, it is assumed to be true for all atoms.

This is only used for secondary structure assignment and cartoon representation.

names: string[]

Names of all atoms in the structure

resids?: number[]

Residue index for all atoms in the structure, if available. This is only used for secondary structure assignment.

resnames?: string[]

Residue name for all atoms in the structure, if available. Atoms without a residue (e.g. water molecules, ions, etc.) should have their resname set to "UNK".

This is used for cartoon representation.

shapes?: {
    [name: string]: ShapeParameters;
}

possible shapes to display, multiple groups of shapes with different names are allowed

Type declaration

size: number

Number of atoms in the structure

x: number[]

x position (cartesian coordinate) of all atoms in the structure

This array should have the same size as Structure.names, and contain values expressed in Angströms.

y: number[]

y position (cartesian coordinate) of all atoms in the structure

This array should have the same size as Structure.names, and contain values expressed in Angströms.

z: number[]

z position (cartesian coordinate) of all atoms in the structure

This array should have the same size as Structure.names, and contain values expressed in Angströms.