Skip to content
Snippets Groups Projects
Commit fa1a71fc authored by Alexander Rose's avatar Alexander Rose
Browse files

added some code docs

parent 27d26fa4
No related branches found
No related tags found
No related merge requests found
/** /**
* Copyright (c) 2017 mol* contributors, licensed under MIT, See LICENSE file for more info. * Copyright (c) 2017-2018 mol* contributors, licensed under MIT, See LICENSE file for more info.
* *
* @author David Sehnal <david.sehnal@gmail.com> * @author David Sehnal <david.sehnal@gmail.com>
* @author Alexander Rose <alexander.rose@weirdbyte.de>
*/ */
import { Column } from 'mol-data/db' import { Column } from 'mol-data/db'
...@@ -13,14 +14,36 @@ export interface AtomicConformation { ...@@ -13,14 +14,36 @@ export interface AtomicConformation {
// ID is part of conformation because mmCIF is a leaky abstraction // ID is part of conformation because mmCIF is a leaky abstraction
// that assigns different atom ids to corresponding atoms in different models // that assigns different atom ids to corresponding atoms in different models
// ... go figure. // ... go figure.
/**
* Uniquely identifies an atom, i.e. even accross models in a mmCIF file.
*/
atomId: Column<number>, atomId: Column<number>,
/**
* The fraction of the atom type present at this site. The sum of the occupancies of all the atom types
* at this site may not significantly exceed 1.0 unless it is a dummy site.
*/
occupancy: Column<number>, occupancy: Column<number>,
/**
* Isotropic atomic displacement parameter, or equivalent isotropic atomic displacement parameter,
* B~eq~, calculated from the anisotropic displacement parameters.
*/
B_iso_or_equiv: Column<number> B_iso_or_equiv: Column<number>
// Coordinates. Generally, not to be accessed directly because the coordinate might be // Coordinates. Generally, not to be accessed directly because the coordinate might be
// transformed by an operator. Use Unit.getPosition instead. // transformed by an operator. Use Unit.getPosition instead.
/**
* The x coordinate in angstroms specified according to a set of orthogonal Cartesian axes.
*/
x: ArrayLike<number>, x: ArrayLike<number>,
/**
* The y coordinate in angstroms specified according to a set of orthogonal Cartesian axes.
*/
y: ArrayLike<number>, y: ArrayLike<number>,
/**
* The z coordinate in angstroms specified according to a set of orthogonal Cartesian axes.
*/
z: ArrayLike<number> z: ArrayLike<number>
} }
\ No newline at end of file
/** /**
* Copyright (c) 2017 mol* contributors, licensed under MIT, See LICENSE file for more info. * Copyright (c) 2017-2018 mol* contributors, licensed under MIT, See LICENSE file for more info.
* *
* @author David Sehnal <david.sehnal@gmail.com> * @author David Sehnal <david.sehnal@gmail.com>
* @author Alexander Rose <alexander.rose@weirdbyte.de>
*/ */
import { Column, Table } from 'mol-data/db' import { Column, Table } from 'mol-data/db'
...@@ -12,10 +13,31 @@ import { ChainIndex, EntityIndex, ResidueIndex, ElementIndex } from '../../index ...@@ -12,10 +13,31 @@ import { ChainIndex, EntityIndex, ResidueIndex, ElementIndex } from '../../index
import SortedRanges from 'mol-data/int/sorted-ranges'; import SortedRanges from 'mol-data/int/sorted-ranges';
export const AtomsSchema = { export const AtomsSchema = {
/**
* The chemical element of this atom site.
* For mmCIF files, this points to atom_type.symbol in the ATOM_TYPE category.
*/
type_symbol: Column.Schema.Aliased<ElementSymbol>(mmCIF.atom_site.type_symbol), type_symbol: Column.Schema.Aliased<ElementSymbol>(mmCIF.atom_site.type_symbol),
/**
* A component of the identifier for this atom site.
* This is a standardized name for the atom within its residue.
* For mmCIF files, this points to chem_comp_atom.atom_id in the CHEM_COMP_ATOM category.
*/
label_atom_id: mmCIF.atom_site.label_atom_id, label_atom_id: mmCIF.atom_site.label_atom_id,
/**
* An alternative identifier for label_atom_id that may be provided by an author
* in order to match the identification used in the publication that describes the structure.
*/
auth_atom_id: mmCIF.atom_site.auth_atom_id, auth_atom_id: mmCIF.atom_site.auth_atom_id,
/**
* A component of the identifier for this atom site.
* Identifies an alternative conformation for this atom site.
*/
label_alt_id: mmCIF.atom_site.label_alt_id, label_alt_id: mmCIF.atom_site.label_alt_id,
/**
* The net integer charge assigned to this atom.
* This is the formal charge assignment normally found in chemical diagrams.
*/
pdbx_formal_charge: mmCIF.atom_site.pdbx_formal_charge pdbx_formal_charge: mmCIF.atom_site.pdbx_formal_charge
// id, occupancy and B_iso_or_equiv are part of conformation // id, occupancy and B_iso_or_equiv are part of conformation
}; };
...@@ -24,19 +46,52 @@ export type AtomsSchema = typeof AtomsSchema ...@@ -24,19 +46,52 @@ export type AtomsSchema = typeof AtomsSchema
export interface Atoms extends Table<AtomsSchema> { } export interface Atoms extends Table<AtomsSchema> { }
export const ResiduesSchema = { export const ResiduesSchema = {
/**
* The group of atoms to which the atom site belongs. This data item is provided for
* compatibility with the original Protein Data Bank format, and only for that purpose.
*/
group_PDB: mmCIF.atom_site.group_PDB, group_PDB: mmCIF.atom_site.group_PDB,
/**
* A component of the identifier for this atom site.
* For mmCIF files, this points to chem_comp.id in the CHEM_COMP category.
*/
label_comp_id: mmCIF.atom_site.label_comp_id, label_comp_id: mmCIF.atom_site.label_comp_id,
/**
* An alternative identifier for atom_site.label_comp_id that may be provided by an author
* in order to match the identification used in the publication that describes the structure.
*/
auth_comp_id: mmCIF.atom_site.auth_comp_id, auth_comp_id: mmCIF.atom_site.auth_comp_id,
/**
* For mmCIF files, this points to entity_poly_seq.num in the ENTITY_POLY_SEQ category.
*/
label_seq_id: mmCIF.atom_site.label_seq_id, label_seq_id: mmCIF.atom_site.label_seq_id,
/**
* An alternative identifier for atom_site.label_seq_id that may be provided by an author
* in order to match the identification used in the publication that describes the structure.
*/
auth_seq_id: mmCIF.atom_site.auth_seq_id, auth_seq_id: mmCIF.atom_site.auth_seq_id,
/**
* PDB insertion code.
*/
pdbx_PDB_ins_code: mmCIF.atom_site.pdbx_PDB_ins_code, pdbx_PDB_ins_code: mmCIF.atom_site.pdbx_PDB_ins_code,
}; };
export type ResiduesSchema = typeof ResiduesSchema export type ResiduesSchema = typeof ResiduesSchema
export interface Residues extends Table<ResiduesSchema> { } export interface Residues extends Table<ResiduesSchema> { }
export const ChainsSchema = { export const ChainsSchema = {
/**
* A component of the identifier for this atom site.
* For mmCIF files, this points to struct_asym.id in the STRUCT_ASYM category.
*/
label_asym_id: mmCIF.atom_site.label_asym_id, label_asym_id: mmCIF.atom_site.label_asym_id,
/**
* An alternative identifier for atomsite.label_asym_id that may be provided by an author
* in order to match the identification used in the publication that describes the structure.
*/
auth_asym_id: mmCIF.atom_site.auth_asym_id, auth_asym_id: mmCIF.atom_site.auth_asym_id,
/**
* For mmCIF files, this points to _entity.id in the ENTITY category.
*/
label_entity_id: mmCIF.atom_site.label_entity_id label_entity_id: mmCIF.atom_site.label_entity_id
} }
export type ChainsSchema = typeof ChainsSchema export type ChainsSchema = typeof ChainsSchema
......
...@@ -2,6 +2,7 @@ ...@@ -2,6 +2,7 @@
* Copyright (c) 2018 mol* contributors, licensed under MIT, See LICENSE file for more info. * Copyright (c) 2018 mol* contributors, licensed under MIT, See LICENSE file for more info.
* *
* @author David Sehnal <david.sehnal@gmail.com> * @author David Sehnal <david.sehnal@gmail.com>
* @author Alexander Rose <alexander.rose@weirdbyte.de>
*/ */
import UUID from 'mol-util/uuid' import UUID from 'mol-util/uuid'
...@@ -14,17 +15,47 @@ export interface CoarseConformation { ...@@ -14,17 +15,47 @@ export interface CoarseConformation {
} }
export interface CoarseSphereConformation { export interface CoarseSphereConformation {
/**
* The x coordinate in angstroms specified according to a set of orthogonal Cartesian axes.
*/
x: ArrayLike<number>, x: ArrayLike<number>,
/**
* The y coordinate in angstroms specified according to a set of orthogonal Cartesian axes.
*/
y: ArrayLike<number>, y: ArrayLike<number>,
/**
* The z coordinate in angstroms specified according to a set of orthogonal Cartesian axes.
*/
z: ArrayLike<number>, z: ArrayLike<number>,
/**
* The radius associated with the primitive sphere object at this position.
*/
radius: ArrayLike<number>, radius: ArrayLike<number>,
/**
* The Root Mean Square Fluctuation (RMSF) observed in the primitive sphere object at this position.
*/
rmsf: ArrayLike<number> rmsf: ArrayLike<number>
} }
export interface CoarseGaussianConformation { export interface CoarseGaussianConformation {
/**
* The x coordinate in angstroms specified according to a set of orthogonal Cartesian axes.
*/
x: ArrayLike<number>, x: ArrayLike<number>,
/**
* The y coordinate in angstroms specified according to a set of orthogonal Cartesian axes.
*/
y: ArrayLike<number>, y: ArrayLike<number>,
/**
* The z coordinate in angstroms specified according to a set of orthogonal Cartesian axes.
*/
z: ArrayLike<number>, z: ArrayLike<number>,
/**
* The weight of the gaussian object.
*/
weight: ArrayLike<number>, weight: ArrayLike<number>,
/**
* Data item of the covariance matrix representing the Gaussian object.
*/
covariance_matrix: ArrayLike<Mat3> covariance_matrix: ArrayLike<Mat3>
} }
\ No newline at end of file
...@@ -23,9 +23,25 @@ export interface CoarsedElementKeys { ...@@ -23,9 +23,25 @@ export interface CoarsedElementKeys {
export interface CoarseElementData { export interface CoarseElementData {
count: number, count: number,
/**
* The entity identifier corresponding to this coarse object.
* In mmCIF files, this points to entity_poly_seq.entity_id in the ENTITY_POLY category.
*/
entity_id: Column<string>, entity_id: Column<string>,
/**
* An asym/strand identifier corresponding to this coarse object.
* In mmCIF files, this points to struct_asym.id in the STRUCT_ASYM category
*/
asym_id: Column<string>, asym_id: Column<string>,
/**
* The leading sequence index corresponding to this coarse object.
* In mmCIF files, this points to entity_poly_seq.num in the ENTITY_POLY category.
*/
seq_id_begin: Column<number>, seq_id_begin: Column<number>,
/**
* The trailing sequence index corresponding to this coarse object.
* In mmCIF files, this points to entity_poly_seq.num in the ENTITY_POLY category.
*/
seq_id_end: Column<number>, seq_id_end: Column<number>,
chainElementSegments: Segmentation<ElementIndex, ChainIndex>, chainElementSegments: Segmentation<ElementIndex, ChainIndex>,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment