Debian Codegraph @

doc/programs/html/dbiblast.html

raw symbols SCIP
1 <HTML>
2
3 <HEAD>
4 <TITLE>
5 EMBOSS: dbiblast
6 </TITLE>
7 </HEAD>
8 <BODY BGCOLOR="#FFFFFF" text="#000000">
9
10 <table align=center border=0 cellspacing=0 cellpadding=0>
11 <tr><td valign=top>
12 <A HREF="/" ONMOUSEOVER="self.status='Go to the EMBOSS home page';return true"><img border=0 src="/images/emboss_icon.jpg" alt="" width=150 height=48></a>
13 </td>
14 <td align=left valign=middle>
15 <b><font size="+6">
16 dbiblast
17 </font></b>
18 </td></tr>
19 </table>
20 <br>&nbsp;
21 <p>
22
23
24 <H2>
25 Wiki
26 </H2>
27
28 The master copies of EMBOSS documentation are available
29 at <a href="http://emboss.open-bio.org/wiki/Appdocs">
30 http://emboss.open-bio.org/wiki/Appdocs</a>
31 on the EMBOSS Wiki.
32
33 <p>
34 Please help by correcting and extending the Wiki pages.
35
36 <H2>
37 Function
38 </H2>
39 Index a BLAST database
40 <H2>
41 Description
42 </H2>
43
44 <b>dbiblast</b> indexes a blast database created by the NCBI indexing programs
45 formatdb, pressdb or setdb, and builds EMBL CD-ROM format index
46 files. This format is used by the software on the EMBL database CD-ROM
47 distribution and by the Staden package in addition to EMBOSS, and
48 appears to be the most generally used and publicly available index
49 file format.
50
51 <p>
52
53 The index files of the blast database format are not useful by
54 themselves as they do not hold the entrynames or accession numbers,
55 but they are used as pointers to the reference and sequence information
56 in the database.
57
58 <p>
59
60 Because there are two sequence types (nucleic acid and protein) and two
61 index formats (blast1 from pressdb or setdb, and blast2 from formatdb)
62 with different index file names, <b>dbiblast</b> will ask about the database
63 type. If the answer is "unknown" <b>dbiblast</b> will test each possible set
64 of file names until one is found.
65
66
67
68 <H2>
69 Usage
70 </H2>
71 Here is a sample session with <b>dbiblast</b>
72 <p>
73 This creates EMBOSS indices for the BLAST database 'swnew'
74 <p>
75
76 <p>
77 <table width="90%"><tr><td bgcolor="#CCFFFF"><pre>
78
79 % <b>dbiblast </b>
80 Index a BLAST database
81 Database name: <b>swnew</b>
82 Database directory [.]: <b>data</b>
83 Wildcard database filename [swnew]: <b></b>
84 Release number [0.0]: <b></b>
85 Index date [00/00/00]: <b></b>
86 N : nucleic
87 P : protein
88 ? : unknown
89 Sequence type [unknown]: <b></b>
90 1 : wublast and setdb/pressdb
91 2 : formatdb
92 0 : unknown
93 Blast index version [unknown]: <b></b>
94 General log output file [outfile.dbiblast]: <b></b>
95
96 </pre></td></tr></table><p>
97 <p>
98 <a href="#output.1">Go to the output files for this example</a><p><p>
99
100
101 <H2>
102 Command line arguments
103 </H2>
104
105 <table CELLSPACING=0 CELLPADDING=3 BGCOLOR="#f5f5ff" ><tr><td>
106 <pre>
107 Index a BLAST database
108 Version: EMBOSS:6.6.0.0
109
110 Standard (Mandatory) qualifiers:
111 [-dbname] string Database name (Any string from 2 to 19
112 characters, matching regular expression
113 /[A-z][A-z0-9_]+/)
114 -directory directory [.] Database directory
115 -filenames string [Database name] Wildcard database filename
116 (Any string)
117 -release string [0.0] Release number (Any string up to 9
118 characters)
119 -date string [00/00/00] Index date (Date string dd/mm/yy)
120 -seqtype menu [unknown] Sequence type (Values: N
121 (nucleic); P (protein); ? (unknown))
122 -blastversion menu [unknown] Blast index version (Values: 1
123 (wublast and setdb/pressdb); 2 (formatdb); 0
124 (unknown))
125 -outfile outfile [*.dbiblast] General log output file
126
127 Additional (Optional) qualifiers: (none)
128 Advanced (Unprompted) qualifiers:
129 -fields menu [acc] Index fields (Values: acc (acnum
130 accession number index); sv (seqvn sequence
131 version and gi number index); des (des
132 description index))
133 -exclude string Wildcard filename(s) to exclude (Any string)
134 -sortoptions string [-T . -k 1,1] Sort options, typically '-T .'
135 to use current directory for work files and
136 '-k 1,1' to force GNU sort to use the first
137 field (Any string)
138 -maxindex integer [0] Maximum index length (Integer 0 or more)
139 -[no]systemsort boolean [Y] Use system sort utility
140 -[no]cleanup boolean [Y] Clean up temporary files
141 -sourcefile boolean Use FASTA source file
142 -indexoutdir outdir [.] Index file output directory
143
144 Associated qualifiers:
145
146 "-directory" associated qualifiers
147 -extension string Default file extension
148
149 "-outfile" associated qualifiers
150 -odirectory string Output directory
151
152 "-indexoutdir" associated qualifiers
153 -extension string Default file extension
154
155 General qualifiers:
156 -auto boolean Turn off prompts
157 -stdout boolean Write first file to standard output
158 -filter boolean Read first file from standard input, write
159 first file to standard output
160 -options boolean Prompt for standard and additional values
161 -debug boolean Write debug output to program.dbg
162 -verbose boolean Report some/full command line options
163 -help boolean Report command line options and exit. More
164 information on associated and general
165 qualifiers can be found with -help -verbose
166 -warning boolean Report warnings
167 -error boolean Report errors
168 -fatal boolean Report fatal errors
169 -die boolean Report dying program messages
170 -version boolean Report version number and exit
171
172 </pre>
173 </td></tr></table>
174 <P>
175 <table border cellspacing=0 cellpadding=3 bgcolor="#ccccff">
176 <tr bgcolor="#FFFFCC">
177 <th align="left">Qualifier</th>
178 <th align="left">Type</th>
179 <th align="left">Description</th>
180 <th align="left">Allowed values</th>
181 <th align="left">Default</th>
182 </tr>
183
184 <tr bgcolor="#FFFFCC">
185 <th align="left" colspan=5>Standard (Mandatory) qualifiers</th>
186 </tr>
187
188 <tr bgcolor="#FFFFCC">
189 <td>[-dbname]<br>(Parameter 1)</td>
190 <td>string</td>
191 <td>Database name</td>
192 <td>Any string from 2 to 19 characters, matching regular expression /[A-z][A-z0-9_]+/</td>
193 <td><b>Required</b></td>
194 </tr>
195
196 <tr bgcolor="#FFFFCC">
197 <td>-directory</td>
198 <td>directory</td>
199 <td>Database directory</td>
200 <td>Directory</td>
201 <td>.</td>
202 </tr>
203
204 <tr bgcolor="#FFFFCC">
205 <td>-filenames</td>
206 <td>string</td>
207 <td>Wildcard database filename</td>
208 <td>Any string</td>
209 <td>Database name</td>
210 </tr>
211
212 <tr bgcolor="#FFFFCC">
213 <td>-release</td>
214 <td>string</td>
215 <td>Release number</td>
216 <td>Any string up to 9 characters</td>
217 <td>0.0</td>
218 </tr>
219
220 <tr bgcolor="#FFFFCC">
221 <td>-date</td>
222 <td>string</td>
223 <td>Index date</td>
224 <td>Date string dd/mm/yy</td>
225 <td>00/00/00</td>
226 </tr>
227
228 <tr bgcolor="#FFFFCC">
229 <td>-seqtype</td>
230 <td>list</td>
231 <td>Sequence type</td>
232 <td><table><tr><td>N</td> <td><i>(nucleic)</i></td></tr><tr><td>P</td> <td><i>(protein)</i></td></tr><tr><td>?</td> <td><i>(unknown)</i></td></tr></table></td>
233 <td>unknown</td>
234 </tr>
235
236 <tr bgcolor="#FFFFCC">
237 <td>-blastversion</td>
238 <td>list</td>
239 <td>Blast index version</td>
240 <td><table><tr><td>1</td> <td><i>(wublast and setdb/pressdb)</i></td></tr><tr><td>2</td> <td><i>(formatdb)</i></td></tr><tr><td>0</td> <td><i>(unknown)</i></td></tr></table></td>
241 <td>unknown</td>
242 </tr>
243
244 <tr bgcolor="#FFFFCC">
245 <td>-outfile</td>
246 <td>outfile</td>
247 <td>General log output file</td>
248 <td>Output file</td>
249 <td><i>&lt;*&gt;</i>.dbiblast</td>
250 </tr>
251
252 <tr bgcolor="#FFFFCC">
253 <th align="left" colspan=5>Additional (Optional) qualifiers</th>
254 </tr>
255
256 <tr>
257 <td colspan=5>(none)</td>
258 </tr>
259
260 <tr bgcolor="#FFFFCC">
261 <th align="left" colspan=5>Advanced (Unprompted) qualifiers</th>
262 </tr>
263
264 <tr bgcolor="#FFFFCC">
265 <td>-fields</td>
266 <td>list</td>
267 <td>Index fields</td>
268 <td><table><tr><td>acc</td> <td><i>(acnum accession number index)</i></td></tr><tr><td>sv</td> <td><i>(seqvn sequence version and gi number index)</i></td></tr><tr><td>des</td> <td><i>(des description index)</i></td></tr></table></td>
269 <td>acc</td>
270 </tr>
271
272 <tr bgcolor="#FFFFCC">
273 <td>-exclude</td>
274 <td>string</td>
275 <td>Wildcard filename(s) to exclude</td>
276 <td>Any string</td>
277 <td>&nbsp;</td>
278 </tr>
279
280 <tr bgcolor="#FFFFCC">
281 <td>-sortoptions</td>
282 <td>string</td>
283 <td>Sort options, typically '-T .' to use current directory for work files and '-k 1,1' to force GNU sort to use the first field</td>
284 <td>Any string</td>
285 <td>-T . -k 1,1</td>
286 </tr>
287
288 <tr bgcolor="#FFFFCC">
289 <td>-maxindex</td>
290 <td>integer</td>
291 <td>Maximum index length</td>
292 <td>Integer 0 or more</td>
293 <td>0</td>
294 </tr>
295
296 <tr bgcolor="#FFFFCC">
297 <td>-[no]systemsort</td>
298 <td>boolean</td>
299 <td>Use system sort utility</td>
300 <td>Boolean value Yes/No</td>
301 <td>Yes</td>
302 </tr>
303
304 <tr bgcolor="#FFFFCC">
305 <td>-[no]cleanup</td>
306 <td>boolean</td>
307 <td>Clean up temporary files</td>
308 <td>Boolean value Yes/No</td>
309 <td>Yes</td>
310 </tr>
311
312 <tr bgcolor="#FFFFCC">
313 <td>-sourcefile</td>
314 <td>boolean</td>
315 <td>Use FASTA source file</td>
316 <td>Boolean value Yes/No</td>
317 <td>No</td>
318 </tr>
319
320 <tr bgcolor="#FFFFCC">
321 <td>-indexoutdir</td>
322 <td>outdir</td>
323 <td>Index file output directory</td>
324 <td>Output directory</td>
325 <td>.</td>
326 </tr>
327
328 <tr bgcolor="#FFFFCC">
329 <th align="left" colspan=5>Associated qualifiers</th>
330 </tr>
331
332 <tr bgcolor="#FFFFCC">
333 <td align="left" colspan=5>"-directory" associated directory qualifiers
334 </td>
335 </tr>
336
337 <tr bgcolor="#FFFFCC">
338 <td> -extension</td>
339 <td>string</td>
340 <td>Default file extension</td>
341 <td>Any string</td>
342 <td>&nbsp;</td>
343 </tr>
344
345 <tr bgcolor="#FFFFCC">
346 <td align="left" colspan=5>"-outfile" associated outfile qualifiers
347 </td>
348 </tr>
349
350 <tr bgcolor="#FFFFCC">
351 <td> -odirectory</td>
352 <td>string</td>
353 <td>Output directory</td>
354 <td>Any string</td>
355 <td>&nbsp;</td>
356 </tr>
357
358 <tr bgcolor="#FFFFCC">
359 <td align="left" colspan=5>"-indexoutdir" associated outdir qualifiers
360 </td>
361 </tr>
362
363 <tr bgcolor="#FFFFCC">
364 <td> -extension</td>
365 <td>string</td>
366 <td>Default file extension</td>
367 <td>Any string</td>
368 <td>&nbsp;</td>
369 </tr>
370
371 <tr bgcolor="#FFFFCC">
372 <th align="left" colspan=5>General qualifiers</th>
373 </tr>
374
375 <tr bgcolor="#FFFFCC">
376 <td> -auto</td>
377 <td>boolean</td>
378 <td>Turn off prompts</td>
379 <td>Boolean value Yes/No</td>
380 <td>N</td>
381 </tr>
382
383 <tr bgcolor="#FFFFCC">
384 <td> -stdout</td>
385 <td>boolean</td>
386 <td>Write first file to standard output</td>
387 <td>Boolean value Yes/No</td>
388 <td>N</td>
389 </tr>
390
391 <tr bgcolor="#FFFFCC">
392 <td> -filter</td>
393 <td>boolean</td>
394 <td>Read first file from standard input, write first file to standard output</td>
395 <td>Boolean value Yes/No</td>
396 <td>N</td>
397 </tr>
398
399 <tr bgcolor="#FFFFCC">
400 <td> -options</td>
401 <td>boolean</td>
402 <td>Prompt for standard and additional values</td>
403 <td>Boolean value Yes/No</td>
404 <td>N</td>
405 </tr>
406
407 <tr bgcolor="#FFFFCC">
408 <td> -debug</td>
409 <td>boolean</td>
410 <td>Write debug output to program.dbg</td>
411 <td>Boolean value Yes/No</td>
412 <td>N</td>
413 </tr>
414
415 <tr bgcolor="#FFFFCC">
416 <td> -verbose</td>
417 <td>boolean</td>
418 <td>Report some/full command line options</td>
419 <td>Boolean value Yes/No</td>
420 <td>Y</td>
421 </tr>
422
423 <tr bgcolor="#FFFFCC">
424 <td> -help</td>
425 <td>boolean</td>
426 <td>Report command line options and exit. More information on associated and general qualifiers can be found with -help -verbose</td>
427 <td>Boolean value Yes/No</td>
428 <td>N</td>
429 </tr>
430
431 <tr bgcolor="#FFFFCC">
432 <td> -warning</td>
433 <td>boolean</td>
434 <td>Report warnings</td>
435 <td>Boolean value Yes/No</td>
436 <td>Y</td>
437 </tr>
438
439 <tr bgcolor="#FFFFCC">
440 <td> -error</td>
441 <td>boolean</td>
442 <td>Report errors</td>
443 <td>Boolean value Yes/No</td>
444 <td>Y</td>
445 </tr>
446
447 <tr bgcolor="#FFFFCC">
448 <td> -fatal</td>
449 <td>boolean</td>
450 <td>Report fatal errors</td>
451 <td>Boolean value Yes/No</td>
452 <td>Y</td>
453 </tr>
454
455 <tr bgcolor="#FFFFCC">
456 <td> -die</td>
457 <td>boolean</td>
458 <td>Report dying program messages</td>
459 <td>Boolean value Yes/No</td>
460 <td>Y</td>
461 </tr>
462
463 <tr bgcolor="#FFFFCC">
464 <td> -version</td>
465 <td>boolean</td>
466 <td>Report version number and exit</td>
467 <td>Boolean value Yes/No</td>
468 <td>N</td>
469 </tr>
470
471 </table>
472
473 <H2>
474 Input file format
475 </H2>
476
477 Any BLAST1 or BLAST2 database index files.
478
479 <p>
480
481 <H2>
482 Output file format
483 </H2>
484
485
486 <a name="output.1"></a>
487 <h3>Output files for usage example </h3>
488 <p><h3>File: division.lkp</h3>
489 <p>This file contains non-printing characters and so cannot be displayed here.
490 <p><h3>File: entrynam.idx</h3>
491 <p>This file contains non-printing characters and so cannot be displayed here.
492 <p><h3>File: acnum.hit</h3>
493 <p>This file contains non-printing characters and so cannot be displayed here.
494 <p><h3>File: acnum.trg</h3>
495 <p>This file contains non-printing characters and so cannot be displayed here.
496 <p><h3>File: outfile.dbiblast</h3>
497 <table width="90%"><tr><td bgcolor="#CCFFCC">
498 <pre>
499 ########################################
500 # Program: dbiblast
501 # Rundate: Mon 15 Jul 2013 12:00:00
502 # Dbname: swnew
503 # Release: 0.0
504 # Date: 15/07/13
505 # CurrentDirectory: /homes/user/test/qa/dbiblast-ex-keep/
506 # IndexDirectory: ./
507 # IndexDirectoryPath: /homes/user/test/qa/dbiblast-ex-keep/
508 # Maxindex: 0
509 # Fields: 2
510 # Field 1: id
511 # Field 2: acc
512 # Directory: /homes/user/test/data/
513 # DirectoryPath: /homes/user/test/data/
514 # Filenames: swnew
515 # Exclude:
516 # Files: 1
517 # File 1: /homes/user/test/data/swnew
518 ########################################
519 # Commandline: dbiblast
520 # -dbname swnew
521 # -directory ../../data
522 ########################################
523
524 filename: '/homes/user/test/data/swnew'
525 id: 9
526 acc: 9
527
528 Index acc: maxlen 6 items 9
529
530 Total 1 files 9 entries (0 duplicates)
531 </pre>
532 </td></tr></table><p>
533 <p>
534
535 <b>dbiblast</b> creates four index files. All are binary but with a
536 simple format.
537
538 <ul>
539
540 <li>division.lkp is the master index file, and has a 300 byte header
541 containing the database name and date plus information on the record
542 size. This header is followed by one record for each database file,
543 giving the full file name for the data file, and optionally a second
544 sequence file.
545
546 <p>
547
548 <li>entryname.idx is the entry name index. It has the same 300 byte
549 header, mainly used to store the record size which will depend on the
550 size of the longest entryname in the database. Each entry is stored in
551 sorted alphanumeric order so that a binary search can be used to
552 efficiently find any record. The record also holds the file number
553 from division.lkp and the offsets in the data and sequence files for
554 that entry.
555
556 <li>acnum.trg holds the accession number information. The file has the
557 usual 300 byte header, and a sorted list of record by accession number.
558 Each accession number record contains the first record number in acnum.hit
559 and the total number of records in acnum.hit so that secondary (duplicated)
560 accession numbers can be searched.
561
562 <li>acnum.hit is a very simple file. After the usual 300 byte header,
563 each record simply holds the record number in entryname.idx. An
564 accession number search will use acnum.trg to find a start position
565 and number of records to read in this file, and will then simply
566 read the entryname.idx records for each entry in turn.
567
568 </ul>
569
570 <H2>
571 Data files
572 </H2>
573
574
575 None.
576
577 <H2>
578 Notes
579 </H2>
580
581 <b>dbiblast</b> can't use the new style of Blast indices. You must
582 create the old style of Blast indices by adding <tt>-A F</tt> to the
583 formatdb command line.
584
585
586 <p>
587
588 Having created the EMBOSS indices for this file, a database can then be
589 defined in the file <b>emboss.defaults</b> as something like:
590
591 <p>
592
593 <pre>
594 DB swnew [
595 type: P
596 format: embl
597 method: blast
598 directory: /data/embl
599 ]
600 </pre>
601
602
603 <h3>Fields Indexed</H3>
604
605 By default, <b>dbiblast</b> will index the ID name and the accession number (if present).
606
607 <br>
608
609 If they are present in your database, you may specify that
610 <b>dbiblast</b> should index the Sequence Version and GI number and the
611 words in the description by using the '-fields' qualifier with the
612 appropriate values.
613
614 <h3>Indexing the Blast database</h3>
615
616 <b>dbiblast</b> can't use the new style of Blast indices. You must
617 create the old style of Blast indices by adding <tt>-A F</tt> to the
618 formatdb command line.
619
620 <p>
621
622 The reason is that NCBI have not documented the new format, so we cannot
623 extend dbiblast to read it.
624
625 <p>
626
627 If you have the original (fasta format) file you can build the previous
628 blast database format with:
629
630 <p>
631
632 <i>formatdb -A F</i>
633
634 <p>
635
636 This turns off the new "ASN.1" formatting. blastall will still work.
637
638
639 <H2>
640 References
641 </H2>
642
643 None.
644
645
646 <H2>
647 Warnings
648 </H2>
649
650
651 <H2>
652 Diagnostic Error Messages
653 </H2>
654
655 None.
656
657
658 <H2>
659 Exit status
660 </H2>
661
662 None.
663
664
665 <H2>
666 Known bugs
667 </H2>
668
669 <b>dbiblast</b> can't use the new style of Blast indices. You must
670 create the old style of Blast indices by adding <tt>-A F</tt> to the
671 formatdb command line.
672
673 <h2><a name="See also">See also</a></h2>
674 <table border cellpadding=4 bgcolor="#FFFFF0">
675 <tr><th>Program name</th>
676 <th>Description</th></tr>
677 <tr>
678 <td><a href="dbifasta.html">dbifasta</a></td>
679 <td>Index a fasta file database</td>
680 </tr>
681
682 <tr>
683 <td><a href="dbiflat.html">dbiflat</a></td>
684 <td>Index a flat file database</td>
685 </tr>
686
687 <tr>
688 <td><a href="dbigcg.html">dbigcg</a></td>
689 <td>Index a GCG formatted database</td>
690 </tr>
691
692 <tr>
693 <td><a href="dbxcompress.html">dbxcompress</a></td>
694 <td>Compress an uncompressed dbx index</td>
695 </tr>
696
697 <tr>
698 <td><a href="dbxedam.html">dbxedam</a></td>
699 <td>Index the EDAM ontology using b+tree indices</td>
700 </tr>
701
702 <tr>
703 <td><a href="dbxfasta.html">dbxfasta</a></td>
704 <td>Index a fasta file database using b+tree indices</td>
705 </tr>
706
707 <tr>
708 <td><a href="dbxflat.html">dbxflat</a></td>
709 <td>Index a flat file database using b+tree indices</td>
710 </tr>
711
712 <tr>
713 <td><a href="dbxgcg.html">dbxgcg</a></td>
714 <td>Index a GCG formatted database using b+tree indices</td>
715 </tr>
716
717 <tr>
718 <td><a href="dbxobo.html">dbxobo</a></td>
719 <td>Index an obo ontology using b+tree indices</td>
720 </tr>
721
722 <tr>
723 <td><a href="dbxreport.html">dbxreport</a></td>
724 <td>Validate index and report internals for dbx databases</td>
725 </tr>
726
727 <tr>
728 <td><a href="dbxresource.html">dbxresource</a></td>
729 <td>Index a data resource catalogue using b+tree indices</td>
730 </tr>
731
732 <tr>
733 <td><a href="dbxstat.html">dbxstat</a></td>
734 <td>Dump statistics for dbx databases</td>
735 </tr>
736
737 <tr>
738 <td><a href="dbxtax.html">dbxtax</a></td>
739 <td>Index NCBI taxonomy using b+tree indices</td>
740 </tr>
741
742 <tr>
743 <td><a href="dbxuncompress.html">dbxuncompress</a></td>
744 <td>Uncompress a compressed dbx index</td>
745 </tr>
746
747 </table>
748 <H2>
749 Author(s)
750 </H2>
751
752 Peter Rice
753 <br>
754 European Bioinformatics Institute, Wellcome Trust Genome Campus, Hinxton, Cambridge CB10 1SD, UK
755
756 <p>
757 Please report all bugs to the EMBOSS bug team (emboss-bug&nbsp;&copy;&nbsp;emboss.open-bio.org) not to the original author.
758 <H2>
759 History
760 </H2>
761
762 Completed December 1999
763
764 <H2>
765 Target users
766 </H2>
767 This program is intended to be used by administrators responsible
768 for software and database installation and maintenance.
769
770 <H2>
771 Comments
772 </H2>
773 None
774
775
776
777 </BODY>
778 </HTML>
779