~ubuntu-branches/ubuntu/lucid/ncbi-tools6/lucid

« back to all changes in this revision

Viewing changes to biostruc/mmdb3.asn

  • Committer: Bazaar Package Importer
  • Author(s): Aaron M. Ucko
  • Date: 2002-04-04 22:13:09 UTC
  • Revision ID: james.westby@ubuntu.com-20020404221309-vfze028rfnlrldct
Tags: upstream-6.1.20011220a
ImportĀ upstreamĀ versionĀ 6.1.20011220a

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
--$Revision: 6.3 $
 
2
--**********************************************************************
 
3
--
 
4
--  Biological Macromolecule 3-D Structure Data Types for MMDB,
 
5
--                A Molecular Modeling Database
 
6
--
 
7
--  Definitions for structural features and biostruc addressing
 
8
--
 
9
--  By Hitomi Ohkawa, Jim Ostell, Chris Hogue and Steve Bryant 
 
10
--
 
11
--  National Center for Biotechnology Information
 
12
--  National Institutes of Health
 
13
--  Bethesda, MD 20894 USA
 
14
--
 
15
--  July, 1996
 
16
--
 
17
--**********************************************************************
 
18
 
 
19
MMDB-Features DEFINITIONS ::=
 
20
 
 
21
BEGIN
 
22
 
 
23
EXPORTS Biostruc-feature-set, Chem-graph-pntrs, Atom-pntrs,
 
24
        Chem-graph-alignment, Sphere, Cone, Cylinder, Brick, Transform,
 
25
        Biostruc-feature-set-id, Biostruc-feature-id;
 
26
 
 
27
IMPORTS Biostruc-id FROM MMDB
 
28
        Molecule-id, Residue-id, Atom-id FROM MMDB-Chemical-graph
 
29
        Model-id, Model-coordinate-set-id FROM MMDB-Structural-model
 
30
        User-object FROM NCBI-General
 
31
        Pub FROM NCBI-Pub;
 
32
 
 
33
-- Named model features refer to sets of residues or atoms, or a region in 
 
34
-- the model space.  A few specific feature types are allowed for compatibility
 
35
-- with PDB usage, but the purpose of a named model feature is simply to
 
36
-- associate various types of information with a set of atoms or 
 
37
-- residues, or a spatially-defined region of the model structure.  They also
 
38
-- support association of various properties with each residue or atom of a
 
39
-- set.
 
40
 
 
41
-- PDB-derived secondary structure defines a single feature, represented as a
 
42
-- sequence of residue motifs, as are the contents of PDB SITE and
 
43
-- FTNOTE records.  NCBI-assigned core and secondary structure descriptions
 
44
-- are also represented as a sequence of residue motifs.
 
45
 
 
46
Biostruc-feature-set ::= SEQUENCE {
 
47
        id              Biostruc-feature-set-id,
 
48
        descr           SEQUENCE OF Biostruc-feature-set-descr OPTIONAL,
 
49
        features        SEQUENCE OF Biostruc-feature }
 
50
 
 
51
Biostruc-feature-set-id ::= INTEGER
 
52
 
 
53
Biostruc-feature-set-descr ::= CHOICE {
 
54
        name                    VisibleString,
 
55
        pdb-comment             VisibleString,
 
56
        other-comment           VisibleString,
 
57
        attribution             Pub }
 
58
 
 
59
-- An explicitly specified type in Biostruc-feature allows for
 
60
-- efficient extraction and indexing of feature sets of a specific type. 
 
61
-- Special types are provided for coloring and rendering, as
 
62
-- as needed by molecular graphics programs.
 
63
 
 
64
Biostruc-feature ::= SEQUENCE {
 
65
        id              Biostruc-feature-id OPTIONAL,
 
66
        name            VisibleString OPTIONAL,
 
67
        type    INTEGER {       helix(1),
 
68
                                strand(2),
 
69
                                sheet(3),
 
70
                                turn(4),
 
71
                                site(5),
 
72
                                footnote(6),
 
73
                                comment(7),      -- new 
 
74
                                subgraph(100),   -- NCBI domain reserved
 
75
                                region(101), 
 
76
                                core(102),       -- user core definition
 
77
                                supercore(103),  -- NCBI reserved
 
78
                                color(150),      -- new
 
79
                                render(151),     -- new
 
80
                                label(152),      -- new
 
81
                                transform(153),  -- new
 
82
                                camera(154),     -- new
 
83
                                script(155),      -- for scripts
 
84
                                alignment(200),  -- VAST reserved 
 
85
                                similarity(201),
 
86
                                multalign(202),  -- multiple alignment
 
87
                                indirect(203),   -- new
 
88
                                cn3dstate(254),  -- Cn3D reserved
 
89
                                other(255) } OPTIONAL,
 
90
        property        CHOICE { 
 
91
                                color           Color-prop,
 
92
                                render          Render-prop,
 
93
                                transform       Transform,
 
94
                                camera          Camera,
 
95
                                script          Biostruc-script,
 
96
                                user            User-object } OPTIONAL,
 
97
        location        CHOICE {
 
98
                                subgraph        Chem-graph-pntrs,
 
99
                                region          Region-pntrs,   
 
100
                                alignment       Chem-graph-alignment,
 
101
                                similarity      Region-similarity, 
 
102
                                indirect        Other-feature } OPTIONAL } -- new
 
103
 
 
104
-- Other-feature allows for specifying location via reference to another
 
105
-- Biostruc-feature and its location.
 
106
 
 
107
Other-feature ::= SEQUENCE {
 
108
        biostruc-id             Biostruc-id,
 
109
        set                     Biostruc-feature-set-id,
 
110
        feature                 Biostruc-feature-id }
 
111
                        
 
112
Biostruc-feature-id ::= INTEGER
 
113
 
 
114
-- Atom, residue or molecule motifs describe a substructure defined by a set
 
115
-- of nodes from the chemical graph. PDB secondary structure features are
 
116
-- described as a residue motif, since they are not associated with any one of
 
117
-- the multiple models that may be provided in a PDB file.  NCBI-assigned
 
118
-- secondary structure is represented in the same way, even though it is
 
119
-- model specific, since this allows for simple mapping of the structural 
 
120
-- feature onto a sequence-only representation. This addressing mode may also 
 
121
-- be used to describe features to be associated with particular atoms, 
 
122
-- as, for example, the chemical shift observed in an NMR experiment.
 
123
 
 
124
Chem-graph-pntrs ::= CHOICE {
 
125
        atoms                   Atom-pntrs,
 
126
        residues                Residue-pntrs,
 
127
        molecules               Molecule-pntrs }
 
128
 
 
129
Atom-pntrs ::= SEQUENCE {
 
130
        number-of-ptrs          INTEGER,
 
131
        molecule-ids            SEQUENCE OF Molecule-id,
 
132
        residue-ids             SEQUENCE OF Residue-id,
 
133
        atom-ids                SEQUENCE OF Atom-id }
 
134
 
 
135
Residue-pntrs ::= CHOICE {
 
136
        explicit                Residue-explicit-pntrs,
 
137
        interval                SEQUENCE OF Residue-interval-pntr }
 
138
 
 
139
Residue-explicit-pntrs ::= SEQUENCE {
 
140
        number-of-ptrs          INTEGER,
 
141
        molecule-ids            SEQUENCE OF Molecule-id,
 
142
        residue-ids             SEQUENCE OF Residue-id }
 
143
 
 
144
Residue-interval-pntr ::= SEQUENCE {
 
145
        molecule-id             Molecule-id,
 
146
        from                    Residue-id,
 
147
        to                      Residue-id }
 
148
 
 
149
Molecule-pntrs ::= SEQUENCE {
 
150
        number-of-ptrs          INTEGER,
 
151
        molecule-ids            SEQUENCE OF Molecule-id }
 
152
 
 
153
-- Region motifs describe features defined by spatial location, such as the
 
154
-- site specified by a coordinate value, or a rgeion within a bounding volume.
 
155
 
 
156
Region-pntrs ::= SEQUENCE {
 
157
        model-id        Model-id,
 
158
        region          CHOICE {
 
159
                                site            SEQUENCE OF Region-coordinates,
 
160
                                boundary        SEQUENCE OF Region-boundary } }
 
161
 
 
162
-- Coordinate sites describe a region in space by reference to individual 
 
163
-- coordinates, in a particular model.  These coordinates may be either the
 
164
-- x, y and z values of atomic coordinates, the triangles of a surface mesh, 
 
165
-- or the grid points of a density model. All are addressed in the same manner,
 
166
-- as coordinate indices which give offsets from the beginning of the 
 
167
-- coordinate data arrays.  A coordinate-index of 5, for example, refers to 
 
168
-- the 5th x, y and z values of an atomic coordinate set, the 5th v1, v2, and v3
 
169
-- values of a triangle mesh, or the 5th value in a density grid.
 
170
 
 
171
-- PDB SITE and FTNOTE records refer to particular atomic coordinates, and they
 
172
-- are represented as a region motif with addresses of type Region-coordinates.
 
173
-- Any names or descriptions provided by PDB are thus associated with the
 
174
-- indicated sites, in the indicated model. 
 
175
 
 
176
Region-coordinates ::= SEQUENCE {
 
177
        model-coord-set-id      Model-coordinate-set-id,
 
178
        number-of-coords        INTEGER OPTIONAL,
 
179
        coordinate-indices      SEQUENCE OF INTEGER OPTIONAL }
 
180
 
 
181
-- Region boundaries are defined by regular solids located in the model space.  
 
182
 
 
183
Region-boundary ::=     CHOICE {        sphere          Sphere,
 
184
                                        cone            Cone,
 
185
                                        cylinder        Cylinder,
 
186
                                        brick           Brick }
 
187
 
 
188
-- A biostruc alignment establishes an equivalence of nodes in the chemical
 
189
-- graphs of two or more biostrucs. This may be mapped to a sequence
 
190
-- alignment in the case of biopolymers.
 
191
-- The 'dimension' component indicates the number of participants
 
192
-- in the alignment.  For pairwise alignments, such as VAST 
 
193
-- structure-structure alignments, the dimension will be always 2, with
 
194
-- biostruc-ids, alignment, and domain each containing two entries for an  
 
195
-- aligned pair.  The 'alignment' component contains a pair of Chem-graph-pntrs
 
196
-- specifying a like number of corresponding residues in each structure.
 
197
-- The 'domain' component specifies a region of each structure considered 
 
198
-- in the alignment.  Only one transform (for the second structure) and
 
199
-- one aligndata (for the pair) are provided for each VAST alignment.
 
200
--
 
201
-- For multiple alignments, a set of components are treated as
 
202
-- parallel arrays of length 'dimension'.
 
203
-- The 'transform' component moves each structure to align it with
 
204
-- the structure specified as the first element in the "parallel" array,
 
205
-- so necessarily the first transform is a NULL transform.
 
206
-- Align-stats are placeholders for scores.
 
207
 
 
208
Chem-graph-alignment ::= SEQUENCE {
 
209
        dimension               INTEGER DEFAULT 2,
 
210
        biostruc-ids            SEQUENCE OF Biostruc-id,
 
211
        alignment               SEQUENCE OF Chem-graph-pntrs,
 
212
        domain                  SEQUENCE OF Chem-graph-pntrs OPTIONAL, 
 
213
        transform               SEQUENCE OF Transform OPTIONAL,
 
214
        aligndata               SEQUENCE OF Align-stats OPTIONAL }
 
215
 
 
216
Align-stats ::= SEQUENCE {
 
217
        descr           VisibleString OPTIONAL,
 
218
        scale-factor    INTEGER OPTIONAL,
 
219
        vast-score      INTEGER OPTIONAL,
 
220
        vast-mlogp      INTEGER OPTIONAL,
 
221
        align-res       INTEGER OPTIONAL,
 
222
        rmsd            INTEGER OPTIONAL,
 
223
        blast-score     INTEGER OPTIONAL,
 
224
        blast-mlogp     INTEGER OPTIONAL,
 
225
        other-score     INTEGER OPTIONAL }              
 
226
 
 
227
-- A biostruc similarity describes spatial features which are similar between
 
228
-- two or more biostrucs.  Similarities are model dependent, and the model and
 
229
-- coordinate set ids of the biostrucs must be specified.  They do not 
 
230
-- necessarily map to a sequence alignment, as the regions referenced may
 
231
-- be pieces of a surface or grid, and thus not uniquely mapable to particular
 
232
-- chemical components.
 
233
 
 
234
Region-similarity ::= SEQUENCE {
 
235
        dimension               INTEGER DEFAULT 2,
 
236
        biostruc-ids            SEQUENCE OF Biostruc-id,
 
237
        similarity              SEQUENCE OF Region-pntrs,
 
238
        transform               SEQUENCE OF Transform }
 
239
 
 
240
-- Geometrical primitives are used in the definition of region motifs, and 
 
241
-- also non-atomic coordinates.  Spheres, cones, cylinders and bricks are 
 
242
-- defined by a few points in the model space.
 
243
 
 
244
Sphere ::= SEQUENCE { 
 
245
        center                  Model-space-point,
 
246
        radius                  RealValue }
 
247
 
 
248
Cone ::= SEQUENCE { 
 
249
        axis-top                Model-space-point,
 
250
        axis-bottom             Model-space-point,
 
251
        radius-bottom           RealValue }
 
252
 
 
253
Cylinder ::= SEQUENCE { 
 
254
        axis-top                Model-space-point,
 
255
        axis-bottom             Model-space-point,
 
256
        radius                  RealValue }
 
257
 
 
258
-- A brick is defined by the coordinates of eight corners.  These are assumed
 
259
-- to appear in the order 000, 001, 010, 011, 100, 101, 110, 111, where the 
 
260
-- digits 0 and 1 refer to respectively to the x, y and z axes of a unit cube.
 
261
-- Opposite edges are assumed to be parallel. 
 
262
 
 
263
Brick ::= SEQUENCE {
 
264
        corner-000              Model-space-point,
 
265
        corner-001              Model-space-point,
 
266
        corner-010              Model-space-point,
 
267
        corner-011              Model-space-point,
 
268
        corner-100              Model-space-point,
 
269
        corner-101              Model-space-point,
 
270
        corner-110              Model-space-point,
 
271
        corner-111              Model-space-point }
 
272
 
 
273
Model-space-point ::= SEQUENCE {
 
274
        scale-factor            INTEGER,
 
275
        x                       INTEGER,
 
276
        y                       INTEGER,
 
277
        z                       INTEGER } 
 
278
 
 
279
RealValue ::= SEQUENCE {
 
280
        scale-factor            INTEGER,
 
281
        scaled-integer-value    INTEGER }
 
282
 
 
283
 
 
284
Transform ::=  SEQUENCE {
 
285
            id  INTEGER,
 
286
            moves SEQUENCE OF Move }
 
287
            
 
288
Move ::= CHOICE {
 
289
        rotate          Rot-matrix,
 
290
        translate       Trans-matrix }
 
291
          
 
292
-- A rotation matrix is defined by 9 numbers, given by row, i.e.,
 
293
-- with column indices varying fastest.
 
294
-- Coordinates, as a matrix with columns x, y, an z, are rotated 
 
295
-- via multiplication with the rotation matrix. 
 
296
-- A translation matrix is defined by 3 numbers, which is added to
 
297
-- the rotated coordinates for specified amount of translation. 
 
298
 
 
299
Rot-matrix ::= SEQUENCE {
 
300
        scale-factor            INTEGER,
 
301
        rot-11                  INTEGER,
 
302
        rot-12                  INTEGER,
 
303
        rot-13                  INTEGER,
 
304
        rot-21                  INTEGER,
 
305
        rot-22                  INTEGER,
 
306
        rot-23                  INTEGER,
 
307
        rot-31                  INTEGER,
 
308
        rot-32                  INTEGER,
 
309
        rot-33                  INTEGER }
 
310
 
 
311
Trans-matrix ::= SEQUENCE {
 
312
        scale-factor            INTEGER,
 
313
        tran-1                  INTEGER,
 
314
        tran-2                  INTEGER,
 
315
        tran-3                  INTEGER }
 
316
 
 
317
-- The camera is a position relative to the world coordinates
 
318
-- of the structure referred to by a location.  
 
319
-- this is used to set the initial position of the
 
320
-- camera using OpenGL.  scale is the value used to scale the
 
321
-- other values from floating point to integer
 
322
 
 
323
Camera ::= SEQUENCE {
 
324
        x               INTEGER,
 
325
        y               INTEGER,
 
326
        distance        INTEGER,
 
327
        angle           INTEGER,
 
328
        scale           INTEGER,
 
329
    modelview   GL-matrix }
 
330
    
 
331
    
 
332
GL-matrix ::= SEQUENCE {
 
333
        scale           INTEGER,
 
334
        m11                     INTEGER,
 
335
        m12                     INTEGER,
 
336
        m13                     INTEGER,
 
337
        m14                     INTEGER,
 
338
        m21                     INTEGER,
 
339
        m22                     INTEGER,
 
340
        m23                     INTEGER,
 
341
        m24                     INTEGER,
 
342
        m31                     INTEGER,
 
343
        m32                     INTEGER,
 
344
        m33                     INTEGER,
 
345
        m34                     INTEGER,
 
346
        m41                     INTEGER,
 
347
        m42                     INTEGER,
 
348
        m43                     INTEGER,
 
349
        m44                     INTEGER }
 
350
 
 
351
 
 
352
Color-prop ::= SEQUENCE {
 
353
        r               INTEGER OPTIONAL, 
 
354
        g               INTEGER OPTIONAL,
 
355
        b               INTEGER OPTIONAL,
 
356
        name            VisibleString OPTIONAL }
 
357
 
 
358
-- Note that Render-prop is compatible with the Annmm specification,
 
359
-- i.e., its numbering schemes do not clash with those in Render-prop.
 
360
 
 
361
Render-prop ::= INTEGER {
 
362
        default         (0),  -- Default view
 
363
        wire            (1),  -- use wireframe 
 
364
        space           (2),  -- use spacefill
 
365
        stick           (3),  -- use stick model (thin cylinders)
 
366
        ballNStick      (4),  -- use ball & stick model
 
367
        thickWire       (5),  -- thicker wireframe
 
368
        hide            (9),  -- don't show this
 
369
        name            (10), -- display its name next to it
 
370
        number          (11), -- display its number next to it 
 
371
        pdbNumber       (12), -- display its PDB number next to it
 
372
        objWireFrame    (150), -- display MMDB surface object as wireframe
 
373
        objPolygons     (151), -- display MMDB surface object as polygons   
 
374
        colorsetCPK     (225), -- color atoms like CPK models
 
375
        colorsetbyChain (226), -- color each chain different
 
376
        colorsetbyTemp  (227), -- color using isotropic Temp factors 
 
377
        colorsetbyRes   (228), -- color using residue properties
 
378
        colorsetbyLen   (229), -- color changes along chain length
 
379
        colorsetbySStru (230), -- color by secondary structure
 
380
        colorsetbyHydro (231), -- color by hydrophobicity
 
381
        colorsetbyObject(246), -- color each object differently
 
382
        colorsetbyDomain(247), -- color each domain differently
 
383
        other           (255)  
 
384
        }
 
385
 
 
386
--  When a Biostruc-Feature with a Biostruc-script is initiated,
 
387
--  it should play the specified steps one at a time, setting the feature-do
 
388
--  list as the active display.
 
389
--  The camera can be set using a feature-do, 
 
390
--  but it may be moved independently with
 
391
--  camera-move, which specifies how to move
 
392
--  the camera dynamically during the step along the path defined (e.g.,
 
393
--  a zoom, a rotate).
 
394
--  Any value of pause (in 1:10th's of a second) will force a pause
 
395
--  after an image is shown.
 
396
--  If waitevent is TRUE, it will await a mouse or keypress and ignore 
 
397
--  the pause value.
 
398
 
 
399
Biostruc-script ::= SEQUENCE OF Biostruc-script-step
 
400
 
 
401
Biostruc-script-step ::= SEQUENCE {
 
402
        step-id                 Step-id,
 
403
        step-name               VisibleString OPTIONAL, 
 
404
        feature-do              SEQUENCE OF Other-feature OPTIONAL,
 
405
        camera-move             Transform OPTIONAL,
 
406
        pause                   INTEGER DEFAULT 10,
 
407
        waitevent               BOOLEAN,
 
408
        extra                   INTEGER, 
 
409
        jump                    Step-id OPTIONAL }
 
410
 
 
411
Step-id ::= INTEGER
 
412
 
 
413
END