1--$Id: blstxml.asn,v 1.1 2002/12/02 19:43:46 dondosha Exp $
2--
3--$Revision: 1.1 $
4--**********************************************************************
5--
6--  ASN.1 for simplified BLAST output in XML
7--  by James Ostell, Yuri Wolf and Sergey Shavirin, 2000
8--
9--
10-- $Log: blstxml.asn,v $
11-- Revision 1.1  2002/12/02 19:43:46  dondosha
12-- Copy of the namesake file in distrib/tools CVS directory
13--
14-- Revision 1.1  2002/12/02 19:42:22  dondosha
15-- Copy of the namesake file in distrib/tools CVS directory
16--
17-- Revision 6.7  2002/07/17 22:28:13  dondosha
18-- Added support for megablast XML output
19--
20-- Revision 6.6  2001/05/03 17:52:16  shavirin
21-- Adopted for usage with mani-iterational XML definition.
22--
23-- Revision 6.4  2000/11/08 20:07:20  shavirin
24-- Added new parameter align_len analogos to the number reported in
25-- the Traditional Blast Output.
26--
27-- Revision 6.3  2000/10/23 20:24:03  shavirin
28-- Few parameters were changed to OPTIONAL to allow XML without results:
29-- failure or no hits found condition.
30--
31-- Revision 6.2  2000/08/11 17:48:35  shavirin
32-- Small fix.
33--
34-- Revision 6.1  2000/08/09 20:43:12  shavirin
35-- Initial revision.
36--
37--
38--**********************************************************************
39
40NCBI-BlastOutput DEFINITIONS ::=
41BEGIN
42
43BlastOutput ::= SEQUENCE {
44	program VisibleString ,		-- BLAST program: blastp, tblastx etc.
45	version VisibleString ,		-- Program version
46	reference VisibleString ,	-- Steven, David, Tom and others
47	db VisibleString ,		-- BLAST Database name
48	query-ID VisibleString ,	-- SeqId of query
49	query-def VisibleString ,	-- Definition line of query
50	query-len INTEGER ,		-- length of query sequence
51	query-seq VisibleString OPTIONAL ,	-- query sequence itself
52	param Parameters,		-- search parameters
53        iterations SEQUENCE OF Iteration,
54        mbstat Statistics OPTIONAL        -- Mega BLAST search statistics
55}
56Iteration ::= SEQUENCE {
57	iter-num INTEGER ,	         -- iteration number
58	query-ID VisibleString OPTIONAL, -- SeqId of query
59	query-def VisibleString OPTIONAL,-- Definition line of query
60	query-len INTEGER OPTIONAL ,	 -- length of query sequence
61	hits SEQUENCE OF Hit OPTIONAL,	 -- Hits one for every db sequence
62	stat Statistics OPTIONAL,	 -- search statistics
63        message VisibleString OPTIONAL   -- Some (error?) information
64}
65Parameters ::= SEQUENCE {
66	matrix VisibleString OPTIONAL ,	-- Matrix used (-M)
67	expect REAL ,			-- Expectation threshold (-e)
68	include REAL OPTIONAL ,		-- Inclusion threshold (-h)
69	sc-match INTEGER OPTIONAL ,	-- match score for NT (-r)
70	sc-mismatch INTEGER OPTIONAL ,	-- mismatch score for NT (-q)
71	gap-open INTEGER ,		-- Gap opening cost (-G)
72	gap-extend INTEGER ,		-- Gap extension cost (-E)
73	filter VisibleString OPTIONAL,  -- Filtering options (-F)
74	pattern VisibleString OPTIONAL,	-- PHI-BLAST pattern
75        entrez-query VisibleString OPTIONAL -- Limit of request to Entrez query
76}
77
78Statistics ::= SEQUENCE {
79	db-num INTEGER ,		-- Number of sequences in BLAST db
80	db-len INTEGER ,		-- Length of BLAST db
81	hsp-len INTEGER ,		-- Effective HSP length
82	eff-space REAL,			-- Effective search space
83        kappa REAL,                     -- Karlin-Altschul parameter K
84        lambda REAL,                    -- Karlin-Altschul parameter Lambda
85        entropy REAL                    -- Karlin-Altschul parameter H
86}
87
88Hit ::= SEQUENCE {
89	num INTEGER ,			-- hit number
90	id VisibleString ,		-- SeqId of subject
91	def VisibleString ,		-- definition line of subject
92	accession VisibleString ,       -- accession
93	len INTEGER ,			-- length of subject
94	hsps SEQUENCE OF Hsp OPTIONAL	-- all HSP regions for the given subject
95}
96
97Hsp ::= SEQUENCE {
98	num INTEGER ,			-- HSP number
99	bit-score REAL ,		-- score (in bits) of HSP
100	score REAL ,			-- score of HSP
101	evalue REAL ,			-- e-value of HSP
102	query-from INTEGER ,		-- start of HSP in query
103	query-to INTEGER ,		-- end of HSP
104	hit-from INTEGER,		-- start of HSP in subject
105	hit-to INTEGER ,		-- end of HSP in subject
106	pattern-from INTEGER OPTIONAL ,	-- start of PHI-BLAST pattern
107	pattern-to INTEGER OPTIONAL ,	-- end of PHI-BLAST pattern
108	query-frame INTEGER OPTIONAL ,	-- translation frame of query
109	hit-frame INTEGER OPTIONAL ,	-- translation frame of subject
110	identity INTEGER OPTIONAL ,	-- number of identities in HSP
111	positive INTEGER OPTIONAL ,	-- number of positives in HSP
112	gaps INTEGER OPTIONAL ,		-- number of gaps in HSP
113	align-len INTEGER OPTIONAL ,	-- length of the alignment used
114	density INTEGER OPTIONAL ,	-- score density
115	qseq VisibleString ,		-- alignment string for the query (with gaps)
116	hseq VisibleString,		-- alignment string for subject (with gaps)
117	midline VisibleString OPTIONAL	-- formating middle line
118}
119
120END
121