NGL@1.0.0-beta.7 Home Manual Reference Source Gallery
import Structure from 'ngl/src/structure/structure.js'
public class | source

Structure

Direct Subclass:

StructureView

Structure

Constructor Summary

Public Constructor
public

constructor(name: String, path: String)

Member Summary

Public Members
public
public
public
public
public
public
public
public
public
public
public
public
public
public
public
public
public
public
public
public
public

id

public
public
public
public
public
public
public

signals: {refreshed: Signal}

public
public
public get
public
public
Private Members
private

_ap

private

_bp

private

_cp

private

_rp

Method Summary

Public Methods
public

Gets the center of the (selected) structure atoms

public

Calls dispose() method of property objects.

public

eachAtom(callback: function(atom: AtomProxy), selection: Selection): undefined

Atom iterator

public

eachBond(callback: function(bond: BondProxy), selection: Selection): undefined

Bond iterator

public

eachChain(callback: function(chain: ChainProxy), selection: Selection): undefined

Chain iterator

public

eachEntity(callback: function(entity: Entity), type: EntityType): undefined

Entity iterator

public

eachModel(callback: function(model: ModelProxy), selection: Selection): undefined

Model iterator

public

eachPolymer(callback: function(polymer: Polymer), selection: Selection): undefined

Polymer iterator

public

eachResidue(callback: function(residue: ResidueProxy), selection: Selection): undefined

Residue iterator

public

eachResidueN(n: Integer, callback: function(residueList: ResidueProxy[])): undefined

Multi-residue iterator

public
public
public
public
public
public

Get a set of atoms

public

Get set of all atoms within the groups of a selection

public

Get set of atoms around a point

public

Get set of atoms around a set of atoms from a selection

public

getAtomSetWithinVolume(volume: Volume, radius: Number, minValue: [type], maxValue: [type], outside: [type]): BitArray

Get set of atoms within a volume

public
public
public
public
public
public
public

getBoundingBox(selection: Selection, box: Box3): Vector3

Gets the bounding box of the (selected) structure atoms

public
public

Get number of unique chainnames

public
public

Gets the principal axes of the (selected) structure atoms

public
public
public
public
public
public
public
public
public

init()

public
public

Public Constructors

public constructor(name: String, path: String) source

Params:

NameTypeAttributeDescription
name String

structure name

path String

source path

Public Members

public atomCount source

public atomMap: AtomMap source

public atomSet source

public atomSetCache source

public atomSetDict source

public atomStore source

public backboneBondStore source

public biomolDict source

public bondCount source

public bondHash: BondHash source

public bondSet source

public bondStore source

public boundingBox: Box3 source

public boxes source

public center: Vector3 source

public chainStore source

public entityList: Entity[] source

public extraData: StructureExtraData source

public frames source

public header: StructureHeader source

public id source

public modelStore source

public name source

public path source

public residueMap: ResidueMap source

public residueStore source

public rungBondStore source

public signals: {refreshed: Signal} source

public spatialHash: SpatialHash source

public title source

public get type source

public unitcell: Unitcell source

public validation: Validation source

Private Members

private _ap source

private _bp source

private _cp source

private _rp source

Public Methods

public atomCenter(selection: Selection): Vector3 source

Gets the center of the (selected) structure atoms

Params:

NameTypeAttributeDescription
selection Selection
  • optional

the selection

Return:

Vector3

the center

public dispose(): undefined source

Calls dispose() method of property objects. Unsets properties to help garbage collection.

Return:

undefined

public eachAtom(callback: function(atom: AtomProxy), selection: Selection): undefined source

Atom iterator

Params:

NameTypeAttributeDescription
callback function(atom: AtomProxy)

the callback

selection Selection
  • optional

the selection

Return:

undefined

public eachBond(callback: function(bond: BondProxy), selection: Selection): undefined source

Bond iterator

Params:

NameTypeAttributeDescription
callback function(bond: BondProxy)

the callback

selection Selection
  • optional

the selection

Return:

undefined

public eachChain(callback: function(chain: ChainProxy), selection: Selection): undefined source

Chain iterator

Params:

NameTypeAttributeDescription
callback function(chain: ChainProxy)

the callback

selection Selection
  • optional

the selection

Return:

undefined

public eachEntity(callback: function(entity: Entity), type: EntityType): undefined source

Entity iterator

Params:

NameTypeAttributeDescription
callback function(entity: Entity)

the callback

type EntityType

entity type

Return:

undefined

public eachModel(callback: function(model: ModelProxy), selection: Selection): undefined source

Model iterator

Params:

NameTypeAttributeDescription
callback function(model: ModelProxy)

the callback

selection Selection
  • optional

the selection

Return:

undefined

public eachPolymer(callback: function(polymer: Polymer), selection: Selection): undefined source

Polymer iterator

Params:

NameTypeAttributeDescription
callback function(polymer: Polymer)

the callback

selection Selection
  • optional

the selection

Return:

undefined

public eachResidue(callback: function(residue: ResidueProxy), selection: Selection): undefined source

Residue iterator

Params:

NameTypeAttributeDescription
callback function(residue: ResidueProxy)

the callback

selection Selection
  • optional

the selection

Return:

undefined

public eachResidueN(n: Integer, callback: function(residueList: ResidueProxy[])): undefined source

Multi-residue iterator

Params:

NameTypeAttributeDescription
n Integer

window size

callback function(residueList: ResidueProxy[])

the callback

Return:

undefined

public finalizeAtoms() source

public finalizeBonds() source

public getAtomData() source

public getAtomIndices() source

public getAtomProxy() source

public getAtomSet(selection: Boolean | Selection | BitArray): BitArray source

Get a set of atoms

Params:

NameTypeAttributeDescription
selection Boolean | Selection | BitArray

object defining how to initialize the atom set. Boolean: init with value; Selection: init with selection; BitArray: return bit array

Return:

BitArray

set of atoms

public getAtomSetWithinGroup(selection: Selection): BitArray source

Get set of all atoms within the groups of a selection

Params:

NameTypeAttributeDescription
selection Selection

the selection object

Return:

BitArray

set of atoms

public getAtomSetWithinPoint(point: Vector3 | AtomProxy, radius: Number): BitArray source

Get set of atoms around a point

Params:

NameTypeAttributeDescription
point Vector3 | AtomProxy

the point

radius Number

radius to select within

Return:

BitArray

set of atoms

public getAtomSetWithinSelection(selection: Selection, radius: Number): BitArray source

Get set of atoms around a set of atoms from a selection

Params:

NameTypeAttributeDescription
selection Selection

the selection object

radius Number

radius to select within

Return:

BitArray

set of atoms

public getAtomSetWithinVolume(volume: Volume, radius: Number, minValue: [type], maxValue: [type], outside: [type]): BitArray source

Get set of atoms within a volume

Params:

NameTypeAttributeDescription
volume Volume

the volume

radius Number

radius to select within

minValue [type]

minimum value to be considered as within the volume

maxValue [type]

maximum value to be considered as within the volume

outside [type]

use only values falling outside of the min/max values

Return:

BitArray

set of atoms

public getBackboneAtomData() source

public getBackboneBondData() source

public getBackboneBondSet() source

public getBondData() source

public getBondProxy() source

public getBondSet() source

public getBoundingBox(selection: Selection, box: Box3): Vector3 source

Gets the bounding box of the (selected) structure atoms

Params:

NameTypeAttributeDescription
selection Selection
  • optional

the selection

box Box3
  • optional

optional target

Return:

Vector3

the box

public getChainProxy() source

public getChainnameCount(selection: Selection): Integer source

Get number of unique chainnames

Params:

NameTypeAttributeDescription
selection Selection

limit count to selection

Return:

Integer

count

public getModelProxy() source

public getPrincipalAxes(selection: Selection): PrincipalAxes source

Gets the principal axes of the (selected) structure atoms

Params:

NameTypeAttributeDescription
selection Selection
  • optional

the selection

Return:

PrincipalAxes

the principal axes

public getResidueProxy() source

public getRungAtomData() source

public getRungBondData() source

public getRungBondSet() source

public getSelection() source

public getSequence() source

public getStructure() source

public hasCoords() source

public init() source

public refreshPosition() source

public updatePosition() source