bio 1.0.0 → 1.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/bin/bioruby +14 -122
- data/bin/br_biofetch.rb +2 -2
- data/bin/br_bioflat.rb +2 -2
- data/bin/br_biogetseq.rb +2 -2
- data/bin/br_pmfetch.rb +3 -3
- data/doc/Changes-0.7.rd +77 -0
- data/doc/KEGG_API.rd +523 -232
- data/doc/KEGG_API.rd.ja +529 -207
- data/doc/Tutorial.rd +48 -11
- data/lib/bio.rb +59 -6
- data/lib/bio/alignment.rb +713 -103
- data/lib/bio/appl/bl2seq/report.rb +2 -18
- data/lib/bio/appl/blast.rb +108 -91
- data/lib/bio/appl/blast/format0.rb +33 -18
- data/lib/bio/appl/blast/format8.rb +6 -20
- data/lib/bio/appl/blast/report.rb +293 -429
- data/lib/bio/appl/blast/rexml.rb +8 -22
- data/lib/bio/appl/blast/wublast.rb +21 -12
- data/lib/bio/appl/blast/xmlparser.rb +180 -183
- data/lib/bio/appl/blat/report.rb +127 -30
- data/lib/bio/appl/clustalw.rb +87 -59
- data/lib/bio/appl/clustalw/report.rb +20 -22
- data/lib/bio/appl/emboss.rb +113 -20
- data/lib/bio/appl/fasta.rb +173 -198
- data/lib/bio/appl/fasta/format10.rb +244 -347
- data/lib/bio/appl/gcg/msf.rb +212 -0
- data/lib/bio/appl/gcg/seq.rb +195 -0
- data/lib/bio/appl/genscan/report.rb +5 -23
- data/lib/bio/appl/hmmer.rb +8 -45
- data/lib/bio/appl/hmmer/report.rb +2 -20
- data/lib/bio/appl/iprscan/report.rb +374 -0
- data/lib/bio/appl/mafft.rb +87 -50
- data/lib/bio/appl/mafft/report.rb +151 -44
- data/lib/bio/appl/muscle.rb +52 -0
- data/lib/bio/appl/phylip/alignment.rb +129 -0
- data/lib/bio/appl/phylip/distance_matrix.rb +96 -0
- data/lib/bio/appl/probcons.rb +41 -0
- data/lib/bio/appl/psort.rb +89 -96
- data/lib/bio/appl/psort/report.rb +6 -22
- data/lib/bio/appl/pts1.rb +263 -0
- data/lib/bio/appl/sim4.rb +26 -36
- data/lib/bio/appl/sim4/report.rb +2 -18
- data/lib/bio/appl/sosui/report.rb +5 -20
- data/lib/bio/appl/spidey/report.rb +2 -2
- data/lib/bio/appl/targetp/report.rb +4 -20
- data/lib/bio/appl/tcoffee.rb +55 -0
- data/lib/bio/appl/tmhmm/report.rb +4 -20
- data/lib/bio/command.rb +235 -64
- data/lib/bio/data/aa.rb +21 -26
- data/lib/bio/data/codontable.rb +2 -20
- data/lib/bio/data/na.rb +19 -4
- data/lib/bio/db.rb +27 -12
- data/lib/bio/db/aaindex.rb +2 -20
- data/lib/bio/db/embl/common.rb +4 -21
- data/lib/bio/db/embl/embl.rb +33 -85
- data/lib/bio/db/embl/sptr.rb +612 -302
- data/lib/bio/db/embl/swissprot.rb +10 -29
- data/lib/bio/db/embl/trembl.rb +10 -29
- data/lib/bio/db/embl/uniprot.rb +10 -29
- data/lib/bio/db/fantom.rb +15 -20
- data/lib/bio/db/fasta.rb +3 -3
- data/lib/bio/db/genbank/common.rb +37 -46
- data/lib/bio/db/genbank/ddbj.rb +6 -18
- data/lib/bio/db/genbank/genbank.rb +47 -186
- data/lib/bio/db/genbank/genpept.rb +4 -17
- data/lib/bio/db/genbank/refseq.rb +4 -17
- data/lib/bio/db/gff.rb +103 -35
- data/lib/bio/db/go.rb +4 -20
- data/lib/bio/db/kegg/brite.rb +26 -36
- data/lib/bio/db/kegg/compound.rb +81 -85
- data/lib/bio/db/kegg/drug.rb +98 -0
- data/lib/bio/db/kegg/enzyme.rb +133 -110
- data/lib/bio/db/kegg/expression.rb +2 -20
- data/lib/bio/db/kegg/genes.rb +208 -238
- data/lib/bio/db/kegg/genome.rb +164 -285
- data/lib/bio/db/kegg/glycan.rb +114 -157
- data/lib/bio/db/kegg/keggtab.rb +242 -303
- data/lib/bio/db/kegg/kgml.rb +117 -160
- data/lib/bio/db/kegg/orthology.rb +112 -0
- data/lib/bio/db/kegg/reaction.rb +54 -69
- data/lib/bio/db/kegg/taxonomy.rb +331 -0
- data/lib/bio/db/lasergene.rb +209 -0
- data/lib/bio/db/litdb.rb +3 -27
- data/lib/bio/db/medline.rb +228 -249
- data/lib/bio/db/nbrf.rb +3 -3
- data/lib/bio/db/newick.rb +510 -0
- data/lib/bio/db/nexus.rb +1854 -0
- data/lib/bio/db/pdb.rb +5 -17
- data/lib/bio/db/pdb/atom.rb +2 -18
- data/lib/bio/db/pdb/chain.rb +2 -18
- data/lib/bio/db/pdb/chemicalcomponent.rb +2 -18
- data/lib/bio/db/pdb/model.rb +2 -18
- data/lib/bio/db/pdb/pdb.rb +73 -34
- data/lib/bio/db/pdb/residue.rb +4 -20
- data/lib/bio/db/pdb/utils.rb +2 -18
- data/lib/bio/db/prosite.rb +403 -422
- data/lib/bio/db/rebase.rb +84 -40
- data/lib/bio/db/soft.rb +404 -0
- data/lib/bio/db/transfac.rb +5 -17
- data/lib/bio/feature.rb +106 -52
- data/lib/bio/io/das.rb +32 -42
- data/lib/bio/io/dbget.rb +2 -20
- data/lib/bio/io/ddbjxml.rb +77 -138
- data/lib/bio/io/ebisoap.rb +158 -0
- data/lib/bio/io/ensembl.rb +229 -0
- data/lib/bio/io/fastacmd.rb +89 -82
- data/lib/bio/io/fetch.rb +163 -96
- data/lib/bio/io/flatfile.rb +170 -73
- data/lib/bio/io/flatfile/bdb.rb +3 -16
- data/lib/bio/io/flatfile/index.rb +2 -2
- data/lib/bio/io/flatfile/indexer.rb +3 -2
- data/lib/bio/io/higet.rb +12 -31
- data/lib/bio/io/keggapi.rb +210 -269
- data/lib/bio/io/ncbisoap.rb +155 -0
- data/lib/bio/io/pubmed.rb +169 -147
- data/lib/bio/io/registry.rb +4 -20
- data/lib/bio/io/soapwsdl.rb +43 -38
- data/lib/bio/io/sql.rb +242 -305
- data/lib/bio/location.rb +407 -285
- data/lib/bio/map.rb +410 -0
- data/lib/bio/pathway.rb +558 -695
- data/lib/bio/reference.rb +272 -75
- data/lib/bio/sequence.rb +255 -13
- data/lib/bio/sequence/aa.rb +71 -10
- data/lib/bio/sequence/common.rb +187 -33
- data/lib/bio/sequence/compat.rb +59 -4
- data/lib/bio/sequence/format.rb +54 -7
- data/lib/bio/sequence/generic.rb +3 -3
- data/lib/bio/sequence/na.rb +328 -26
- data/lib/bio/shell.rb +11 -4
- data/lib/bio/shell/core.rb +221 -160
- data/lib/bio/shell/demo.rb +18 -15
- data/lib/bio/shell/interface.rb +14 -12
- data/lib/bio/shell/irb.rb +95 -0
- data/lib/bio/shell/object.rb +45 -26
- data/lib/bio/shell/plugin/blast.rb +42 -0
- data/lib/bio/shell/plugin/codon.rb +22 -14
- data/lib/bio/shell/plugin/das.rb +58 -0
- data/lib/bio/shell/plugin/emboss.rb +2 -2
- data/lib/bio/shell/plugin/entry.rb +22 -11
- data/lib/bio/shell/plugin/flatfile.rb +2 -2
- data/lib/bio/shell/plugin/keggapi.rb +13 -6
- data/lib/bio/shell/plugin/midi.rb +4 -4
- data/lib/bio/shell/plugin/obda.rb +2 -2
- data/lib/bio/shell/plugin/psort.rb +56 -0
- data/lib/bio/shell/plugin/seq.rb +35 -8
- data/lib/bio/shell/plugin/soap.rb +87 -0
- data/lib/bio/shell/rails/vendor/plugins/generators/bioruby/bioruby_generator.rb +29 -0
- data/lib/bio/shell/rails/vendor/plugins/generators/bioruby/templates/_classes.rhtml +4 -0
- data/lib/bio/shell/rails/vendor/plugins/generators/bioruby/templates/_log.rhtml +27 -0
- data/lib/bio/shell/rails/vendor/plugins/generators/bioruby/templates/_methods.rhtml +11 -0
- data/lib/bio/shell/rails/vendor/plugins/generators/bioruby/templates/_modules.rhtml +4 -0
- data/lib/bio/shell/rails/vendor/plugins/generators/bioruby/templates/_variables.rhtml +7 -0
- data/lib/bio/shell/rails/vendor/plugins/generators/bioruby/templates/bioruby-bg.gif +0 -0
- data/lib/bio/shell/rails/vendor/plugins/generators/bioruby/templates/bioruby-console.png +0 -0
- data/lib/bio/shell/rails/{public/images/icon.png → vendor/plugins/generators/bioruby/templates/bioruby-gem.png} +0 -0
- data/lib/bio/shell/rails/vendor/plugins/generators/bioruby/templates/bioruby-link.gif +0 -0
- data/lib/bio/shell/rails/vendor/plugins/generators/bioruby/templates/bioruby.css +369 -0
- data/lib/bio/shell/rails/vendor/plugins/generators/bioruby/templates/bioruby.rhtml +47 -0
- data/lib/bio/shell/rails/vendor/plugins/generators/bioruby/templates/bioruby_controller.rb +144 -0
- data/lib/bio/shell/rails/vendor/plugins/generators/bioruby/templates/bioruby_helper.rb +47 -0
- data/lib/bio/shell/rails/vendor/plugins/generators/bioruby/templates/commands.rhtml +8 -0
- data/lib/bio/shell/rails/vendor/plugins/generators/bioruby/templates/history.rhtml +10 -0
- data/lib/bio/shell/rails/vendor/plugins/generators/bioruby/templates/index.rhtml +22 -0
- data/lib/bio/shell/script.rb +25 -0
- data/lib/bio/shell/setup.rb +109 -0
- data/lib/bio/shell/web.rb +70 -58
- data/lib/bio/tree.rb +850 -0
- data/lib/bio/util/color_scheme.rb +84 -107
- data/lib/bio/util/color_scheme/buried.rb +5 -24
- data/lib/bio/util/color_scheme/helix.rb +5 -24
- data/lib/bio/util/color_scheme/hydropathy.rb +5 -24
- data/lib/bio/util/color_scheme/nucleotide.rb +5 -24
- data/lib/bio/util/color_scheme/strand.rb +5 -24
- data/lib/bio/util/color_scheme/taylor.rb +5 -24
- data/lib/bio/util/color_scheme/turn.rb +5 -24
- data/lib/bio/util/color_scheme/zappo.rb +5 -24
- data/lib/bio/util/contingency_table.rb +70 -43
- data/lib/bio/util/restriction_enzyme.rb +228 -0
- data/lib/bio/util/restriction_enzyme/analysis.rb +249 -0
- data/lib/bio/util/restriction_enzyme/analysis_basic.rb +217 -0
- data/lib/bio/util/restriction_enzyme/cut_symbol.rb +107 -0
- data/lib/bio/util/restriction_enzyme/double_stranded.rb +321 -0
- data/lib/bio/util/restriction_enzyme/double_stranded/aligned_strands.rb +130 -0
- data/lib/bio/util/restriction_enzyme/double_stranded/cut_location_pair.rb +103 -0
- data/lib/bio/util/restriction_enzyme/double_stranded/cut_location_pair_in_enzyme_notation.rb +38 -0
- data/lib/bio/util/restriction_enzyme/double_stranded/cut_locations.rb +76 -0
- data/lib/bio/util/restriction_enzyme/double_stranded/cut_locations_in_enzyme_notation.rb +107 -0
- data/lib/bio/util/restriction_enzyme/enzymes.yaml +7061 -0
- data/lib/bio/util/restriction_enzyme/range/cut_range.rb +24 -0
- data/lib/bio/util/restriction_enzyme/range/cut_ranges.rb +47 -0
- data/lib/bio/util/restriction_enzyme/range/horizontal_cut_range.rb +67 -0
- data/lib/bio/util/restriction_enzyme/range/sequence_range.rb +257 -0
- data/lib/bio/util/restriction_enzyme/range/sequence_range/calculated_cuts.rb +242 -0
- data/lib/bio/util/restriction_enzyme/range/sequence_range/fragment.rb +51 -0
- data/lib/bio/util/restriction_enzyme/range/sequence_range/fragments.rb +41 -0
- data/lib/bio/util/restriction_enzyme/range/vertical_cut_range.rb +77 -0
- data/lib/bio/util/restriction_enzyme/single_strand.rb +199 -0
- data/lib/bio/util/restriction_enzyme/single_strand/cut_locations_in_enzyme_notation.rb +135 -0
- data/lib/bio/util/restriction_enzyme/single_strand_complement.rb +23 -0
- data/lib/bio/util/restriction_enzyme/string_formatting.rb +111 -0
- data/lib/bio/util/sirna.rb +4 -22
- data/sample/color_scheme_na.rb +4 -12
- data/sample/enzymes.rb +78 -0
- data/sample/goslim.rb +5 -13
- data/sample/psortplot_html.rb +4 -12
- data/test/data/blast/2.2.15.blastp.m7 +876 -0
- data/test/data/embl/AB090716.embl.rel89 +63 -0
- data/test/data/fasta/example1.txt +75 -0
- data/test/data/fasta/example2.txt +21 -0
- data/test/data/iprscan/merged.raw +32 -0
- data/test/data/iprscan/merged.txt +74 -0
- data/test/data/soft/GDS100_partial.soft +92 -0
- data/test/data/soft/GSE3457_family_partial.soft +874 -0
- data/test/functional/bio/io/test_ensembl.rb +103 -0
- data/test/functional/bio/io/test_soapwsdl.rb +5 -17
- data/test/unit/bio/appl/bl2seq/test_report.rb +2 -2
- data/test/unit/bio/appl/blast/test_report.rb +3 -16
- data/test/unit/bio/appl/blast/test_xmlparser.rb +4 -16
- data/test/unit/bio/appl/genscan/test_report.rb +3 -16
- data/test/unit/bio/appl/hmmer/test_report.rb +3 -16
- data/test/unit/bio/appl/iprscan/test_report.rb +338 -0
- data/test/unit/bio/appl/mafft/test_report.rb +63 -0
- data/test/unit/bio/appl/sosui/test_report.rb +3 -16
- data/test/unit/bio/appl/targetp/test_report.rb +3 -16
- data/test/unit/bio/appl/test_blast.rb +3 -16
- data/test/unit/bio/appl/test_fasta.rb +4 -16
- data/test/unit/bio/appl/test_pts1.rb +140 -0
- data/test/unit/bio/appl/tmhmm/test_report.rb +3 -16
- data/test/unit/bio/data/test_aa.rb +4 -17
- data/test/unit/bio/data/test_codontable.rb +3 -16
- data/test/unit/bio/data/test_na.rb +3 -3
- data/test/unit/bio/db/embl/test_common.rb +3 -16
- data/test/unit/bio/db/embl/test_embl.rb +3 -16
- data/test/unit/bio/db/embl/test_embl_rel89.rb +219 -0
- data/test/unit/bio/db/embl/test_sptr.rb +1548 -41
- data/test/unit/bio/db/embl/test_uniprot.rb +3 -16
- data/test/unit/bio/db/kegg/test_genes.rb +3 -16
- data/test/unit/bio/db/pdb/test_pdb.rb +7 -24
- data/test/unit/bio/db/test_aaindex.rb +2 -2
- data/test/unit/bio/db/test_fasta.rb +3 -16
- data/test/unit/bio/db/test_gff.rb +3 -16
- data/test/unit/bio/db/test_lasergene.rb +95 -0
- data/test/unit/bio/db/test_newick.rb +56 -0
- data/test/unit/bio/db/test_nexus.rb +360 -0
- data/test/unit/bio/db/test_prosite.rb +5 -18
- data/test/unit/bio/db/test_rebase.rb +11 -25
- data/test/unit/bio/db/test_soft.rb +138 -0
- data/test/unit/bio/io/test_ddbjxml.rb +5 -17
- data/test/unit/bio/io/test_ensembl.rb +109 -0
- data/test/unit/bio/io/test_fastacmd.rb +3 -16
- data/test/unit/bio/io/test_flatfile.rb +237 -0
- data/test/unit/bio/io/test_soapwsdl.rb +4 -17
- data/test/unit/bio/sequence/test_aa.rb +3 -3
- data/test/unit/bio/sequence/test_common.rb +3 -16
- data/test/unit/bio/sequence/test_compat.rb +3 -16
- data/test/unit/bio/sequence/test_na.rb +29 -3
- data/test/unit/bio/shell/plugin/test_seq.rb +8 -8
- data/test/unit/bio/test_alignment.rb +16 -27
- data/test/unit/bio/test_command.rb +242 -25
- data/test/unit/bio/test_db.rb +3 -16
- data/test/unit/bio/test_feature.rb +4 -16
- data/test/unit/bio/test_location.rb +4 -16
- data/test/unit/bio/test_map.rb +230 -0
- data/test/unit/bio/test_pathway.rb +4 -16
- data/test/unit/bio/test_reference.rb +2 -2
- data/test/unit/bio/test_sequence.rb +7 -19
- data/test/unit/bio/test_shell.rb +3 -16
- data/test/unit/bio/test_tree.rb +593 -0
- data/test/unit/bio/util/restriction_enzyme/analysis/test_calculated_cuts.rb +299 -0
- data/test/unit/bio/util/restriction_enzyme/analysis/test_cut_ranges.rb +103 -0
- data/test/unit/bio/util/restriction_enzyme/analysis/test_sequence_range.rb +240 -0
- data/test/unit/bio/util/restriction_enzyme/double_stranded/test_aligned_strands.rb +100 -0
- data/test/unit/bio/util/restriction_enzyme/double_stranded/test_cut_location_pair.rb +75 -0
- data/test/unit/bio/util/restriction_enzyme/double_stranded/test_cut_location_pair_in_enzyme_notation.rb +73 -0
- data/test/unit/bio/util/restriction_enzyme/double_stranded/test_cut_locations.rb +53 -0
- data/test/unit/bio/util/restriction_enzyme/double_stranded/test_cut_locations_in_enzyme_notation.rb +104 -0
- data/test/unit/bio/util/restriction_enzyme/single_strand/test_cut_locations_in_enzyme_notation.rb +83 -0
- data/test/unit/bio/util/restriction_enzyme/test_analysis.rb +246 -0
- data/test/unit/bio/util/restriction_enzyme/test_cut_symbol.rb +44 -0
- data/test/unit/bio/util/restriction_enzyme/test_double_stranded.rb +115 -0
- data/test/unit/bio/util/restriction_enzyme/test_single_strand.rb +147 -0
- data/test/unit/bio/util/restriction_enzyme/test_single_strand_complement.rb +147 -0
- data/test/unit/bio/util/restriction_enzyme/test_string_formatting.rb +60 -0
- data/test/unit/bio/util/test_color_scheme.rb +6 -18
- data/test/unit/bio/util/test_contingency_table.rb +6 -18
- data/test/unit/bio/util/test_restriction_enzyme.rb +42 -0
- data/test/unit/bio/util/test_sirna.rb +3 -16
- metadata +228 -169
- data/doc/BioRuby.rd.ja +0 -225
- data/doc/Design.rd.ja +0 -341
- data/doc/TODO.rd.ja +0 -138
- data/lib/bio/appl/fasta/format6.rb +0 -37
- data/lib/bio/db/kegg/cell.rb +0 -88
- data/lib/bio/db/kegg/ko.rb +0 -178
- data/lib/bio/shell/rails/Rakefile +0 -10
- data/lib/bio/shell/rails/app/controllers/application.rb +0 -4
- data/lib/bio/shell/rails/app/controllers/shell_controller.rb +0 -94
- data/lib/bio/shell/rails/app/helpers/application_helper.rb +0 -3
- data/lib/bio/shell/rails/app/models/shell_connection.rb +0 -30
- data/lib/bio/shell/rails/app/views/layouts/shell.rhtml +0 -37
- data/lib/bio/shell/rails/app/views/shell/history.rhtml +0 -5
- data/lib/bio/shell/rails/app/views/shell/index.rhtml +0 -2
- data/lib/bio/shell/rails/app/views/shell/show.rhtml +0 -13
- data/lib/bio/shell/rails/config/boot.rb +0 -19
- data/lib/bio/shell/rails/config/database.yml +0 -85
- data/lib/bio/shell/rails/config/environment.rb +0 -53
- data/lib/bio/shell/rails/config/environments/development.rb +0 -19
- data/lib/bio/shell/rails/config/environments/production.rb +0 -19
- data/lib/bio/shell/rails/config/environments/test.rb +0 -19
- data/lib/bio/shell/rails/config/routes.rb +0 -19
- data/lib/bio/shell/rails/doc/README_FOR_APP +0 -2
- data/lib/bio/shell/rails/public/404.html +0 -8
- data/lib/bio/shell/rails/public/500.html +0 -8
- data/lib/bio/shell/rails/public/dispatch.cgi +0 -10
- data/lib/bio/shell/rails/public/dispatch.fcgi +0 -24
- data/lib/bio/shell/rails/public/dispatch.rb +0 -10
- data/lib/bio/shell/rails/public/favicon.ico +0 -0
- data/lib/bio/shell/rails/public/images/rails.png +0 -0
- data/lib/bio/shell/rails/public/index.html +0 -277
- data/lib/bio/shell/rails/public/javascripts/controls.js +0 -750
- data/lib/bio/shell/rails/public/javascripts/dragdrop.js +0 -584
- data/lib/bio/shell/rails/public/javascripts/effects.js +0 -854
- data/lib/bio/shell/rails/public/javascripts/prototype.js +0 -1785
- data/lib/bio/shell/rails/public/robots.txt +0 -1
- data/lib/bio/shell/rails/public/stylesheets/main.css +0 -187
- data/lib/bio/shell/rails/script/about +0 -3
- data/lib/bio/shell/rails/script/breakpointer +0 -3
- data/lib/bio/shell/rails/script/console +0 -3
- data/lib/bio/shell/rails/script/destroy +0 -3
- data/lib/bio/shell/rails/script/generate +0 -3
- data/lib/bio/shell/rails/script/performance/benchmarker +0 -3
- data/lib/bio/shell/rails/script/performance/profiler +0 -3
- data/lib/bio/shell/rails/script/plugin +0 -3
- data/lib/bio/shell/rails/script/process/reaper +0 -3
- data/lib/bio/shell/rails/script/process/spawner +0 -3
- data/lib/bio/shell/rails/script/process/spinner +0 -3
- data/lib/bio/shell/rails/script/runner +0 -3
- data/lib/bio/shell/rails/script/server +0 -42
- data/lib/bio/shell/rails/test/test_helper.rb +0 -28
|
@@ -1,23 +1,10 @@
|
|
|
1
1
|
#
|
|
2
|
-
# bio/appl/blast/report.rb - BLAST Report class
|
|
2
|
+
# = bio/appl/blast/report.rb - BLAST Report class
|
|
3
3
|
#
|
|
4
|
-
#
|
|
4
|
+
# Copyright:: Copyright (C) 2003 Toshiaki Katayama <k@bioruby.org>
|
|
5
|
+
# License:: The Ruby License
|
|
5
6
|
#
|
|
6
|
-
#
|
|
7
|
-
# modify it under the terms of the GNU Lesser General Public
|
|
8
|
-
# License as published by the Free Software Foundation; either
|
|
9
|
-
# version 2 of the License, or (at your option) any later version.
|
|
10
|
-
#
|
|
11
|
-
# This library is distributed in the hope that it will be useful,
|
|
12
|
-
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
13
|
-
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
14
|
-
# Lesser General Public License for more details.
|
|
15
|
-
#
|
|
16
|
-
# You should have received a copy of the GNU Lesser General Public
|
|
17
|
-
# License along with this library; if not, write to the Free Software
|
|
18
|
-
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
19
|
-
#
|
|
20
|
-
# $Id: report.rb,v 1.9 2005/09/26 13:00:04 k Exp $
|
|
7
|
+
# $Id: report.rb,v 1.11 2007/04/05 23:35:39 trevor Exp $
|
|
21
8
|
#
|
|
22
9
|
|
|
23
10
|
require 'bio/appl/blast'
|
|
@@ -26,182 +13,320 @@ require 'bio/appl/blast/rexml'
|
|
|
26
13
|
require 'bio/appl/blast/format8'
|
|
27
14
|
|
|
28
15
|
module Bio
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
class Report
|
|
16
|
+
class Blast
|
|
32
17
|
|
|
33
|
-
|
|
34
|
-
|
|
18
|
+
# = Bio::Blast::Report
|
|
19
|
+
#
|
|
20
|
+
# Parsed results of the blast execution for Tab-delimited and XML output
|
|
21
|
+
# format. Tab-delimited reports are consists of
|
|
22
|
+
#
|
|
23
|
+
# Query id,
|
|
24
|
+
# Subject id,
|
|
25
|
+
# percent of identity,
|
|
26
|
+
# alignment length,
|
|
27
|
+
# number of mismatches (not including gaps),
|
|
28
|
+
# number of gap openings,
|
|
29
|
+
# start of alignment in query,
|
|
30
|
+
# end of alignment in query,
|
|
31
|
+
# start of alignment in subject,
|
|
32
|
+
# end of alignment in subject,
|
|
33
|
+
# expected value,
|
|
34
|
+
# bit score.
|
|
35
|
+
#
|
|
36
|
+
# according to the MEGABLAST document (README.mbl). As for XML output,
|
|
37
|
+
# see the following DTDs.
|
|
38
|
+
#
|
|
39
|
+
# * http://www.ncbi.nlm.nih.gov/dtd/NCBI_BlastOutput.dtd
|
|
40
|
+
# * http://www.ncbi.nlm.nih.gov/dtd/NCBI_BlastOutput.mod
|
|
41
|
+
# * http://www.ncbi.nlm.nih.gov/dtd/NCBI_Entity.mod
|
|
42
|
+
#
|
|
43
|
+
class Report
|
|
35
44
|
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
end
|
|
39
|
-
def self.rexml(data)
|
|
40
|
-
self.new(data, :rexml)
|
|
41
|
-
end
|
|
42
|
-
def self.tab(data)
|
|
43
|
-
self.new(data, :tab)
|
|
44
|
-
end
|
|
45
|
+
# for Bio::FlatFile support (only for XML data)
|
|
46
|
+
DELIMITER = RS = "</BlastOutput>\n"
|
|
45
47
|
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
else
|
|
51
|
-
rexml_parse(data)
|
|
52
|
-
end
|
|
53
|
-
else
|
|
54
|
-
tab_parse(data)
|
|
55
|
-
end
|
|
56
|
-
end
|
|
57
|
-
private :auto_parse
|
|
58
|
-
|
|
59
|
-
def initialize(data, parser = nil)
|
|
60
|
-
@iterations = []
|
|
61
|
-
@parameters = {}
|
|
62
|
-
case parser
|
|
63
|
-
when :xmlparser # format 7
|
|
64
|
-
xmlparser_parse(data)
|
|
65
|
-
when :rexml # format 7
|
|
66
|
-
rexml_parse(data)
|
|
67
|
-
when :tab # format 8
|
|
68
|
-
tab_parse(data)
|
|
69
|
-
else
|
|
70
|
-
auto_parse(data)
|
|
71
|
-
end
|
|
72
|
-
end
|
|
73
|
-
attr_reader :iterations, :parameters,
|
|
74
|
-
:program, :version, :reference, :db, :query_id, :query_def, :query_len
|
|
75
|
-
|
|
76
|
-
# shortcut for @parameters
|
|
77
|
-
def matrix; @parameters['matrix']; end
|
|
78
|
-
def expect; @parameters['expect'].to_i; end
|
|
79
|
-
def inclusion; @parameters['include'].to_i; end
|
|
80
|
-
def sc_match; @parameters['sc-match'].to_i; end
|
|
81
|
-
def sc_mismatch; @parameters['sc-mismatch'].to_i; end
|
|
82
|
-
def gap_open; @parameters['gap-open'].to_i; end
|
|
83
|
-
def gap_extend; @parameters['gap-extend'].to_i; end
|
|
84
|
-
def filter; @parameters['filter']; end
|
|
85
|
-
def pattern; @parameters['pattern']; end
|
|
86
|
-
def entrez_query; @parameters['entrez-query']; end
|
|
87
|
-
|
|
88
|
-
# <for blastpgp>
|
|
89
|
-
def each_iteration
|
|
90
|
-
@iterations.each do |x|
|
|
91
|
-
yield x
|
|
92
|
-
end
|
|
93
|
-
end
|
|
48
|
+
# Specify to use XMLParser to parse XML (-m 7) output.
|
|
49
|
+
def self.xmlparser(data)
|
|
50
|
+
self.new(data, :xmlparser)
|
|
51
|
+
end
|
|
94
52
|
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
end
|
|
100
|
-
end
|
|
101
|
-
alias each each_hit
|
|
53
|
+
# Specify to use REXML to parse XML (-m 7) output.
|
|
54
|
+
def self.rexml(data)
|
|
55
|
+
self.new(data, :rexml)
|
|
56
|
+
end
|
|
102
57
|
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
58
|
+
# Specify to use tab delimited output parser.
|
|
59
|
+
def self.tab(data)
|
|
60
|
+
self.new(data, :tab)
|
|
61
|
+
end
|
|
107
62
|
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
def hsp_len; statistics['hsp-len']; end
|
|
115
|
-
def eff_space; statistics['eff-space']; end
|
|
116
|
-
def kappa; statistics['kappa']; end
|
|
117
|
-
def lambda; statistics['lambda']; end
|
|
118
|
-
def entropy; statistics['entropy']; end
|
|
119
|
-
|
|
120
|
-
# shortcut for the last iteration's message (for checking 'CONVERGED')
|
|
121
|
-
def message
|
|
122
|
-
@iterations.last.message
|
|
63
|
+
def auto_parse(data)
|
|
64
|
+
if /<?xml/.match(data[/.*/])
|
|
65
|
+
if defined?(XMLParser)
|
|
66
|
+
xmlparser_parse(data)
|
|
67
|
+
else
|
|
68
|
+
rexml_parse(data)
|
|
123
69
|
end
|
|
70
|
+
else
|
|
71
|
+
tab_parse(data)
|
|
72
|
+
end
|
|
73
|
+
end
|
|
74
|
+
private :auto_parse
|
|
75
|
+
|
|
76
|
+
# Passing a BLAST output from 'blastall -m 7' or '-m 8' as a String.
|
|
77
|
+
# Formats are auto detected.
|
|
78
|
+
def initialize(data, parser = nil)
|
|
79
|
+
@iterations = []
|
|
80
|
+
@parameters = {}
|
|
81
|
+
case parser
|
|
82
|
+
when :xmlparser # format 7
|
|
83
|
+
xmlparser_parse(data)
|
|
84
|
+
when :rexml # format 7
|
|
85
|
+
rexml_parse(data)
|
|
86
|
+
when :tab # format 8
|
|
87
|
+
tab_parse(data)
|
|
88
|
+
else
|
|
89
|
+
auto_parse(data)
|
|
90
|
+
end
|
|
91
|
+
end
|
|
124
92
|
|
|
93
|
+
# Returns an Array of Bio::Blast::Report::Iteration objects.
|
|
94
|
+
attr_reader :iterations
|
|
95
|
+
|
|
96
|
+
# Returns a Hash containing execution parameters. Valid keys are:
|
|
97
|
+
# 'matrix', 'expect', 'include', 'sc-match', 'sc-mismatch',
|
|
98
|
+
# 'gap-open', 'gap-extend', 'filter'
|
|
99
|
+
attr_reader :parameters
|
|
100
|
+
|
|
101
|
+
# Shortcut for BlastOutput values.
|
|
102
|
+
attr_reader :program, :version, :reference, :db, :query_id, :query_def, :query_len
|
|
103
|
+
|
|
104
|
+
# Matrix used (-M) : shortcuts for @parameters
|
|
105
|
+
def matrix; @parameters['matrix']; end
|
|
106
|
+
# Expectation threshold (-e) : shortcuts for @parameters
|
|
107
|
+
def expect; @parameters['expect'].to_i; end
|
|
108
|
+
# Inclusion threshold (-h) : shortcuts for @parameters
|
|
109
|
+
def inclusion; @parameters['include'].to_i; end
|
|
110
|
+
# Match score for NT (-r) : shortcuts for @parameters
|
|
111
|
+
def sc_match; @parameters['sc-match'].to_i; end
|
|
112
|
+
# Mismatch score for NT (-q) : shortcuts for @parameters
|
|
113
|
+
def sc_mismatch; @parameters['sc-mismatch'].to_i; end
|
|
114
|
+
# Gap opening cost (-G) : shortcuts for @parameters
|
|
115
|
+
def gap_open; @parameters['gap-open'].to_i; end
|
|
116
|
+
# Gap extension cost (-E) : shortcuts for @parameters
|
|
117
|
+
def gap_extend; @parameters['gap-extend'].to_i; end
|
|
118
|
+
# Filtering options (-F) : shortcuts for @parameters
|
|
119
|
+
def filter; @parameters['filter']; end
|
|
120
|
+
# PHI-BLAST pattern : shortcuts for @parameters
|
|
121
|
+
def pattern; @parameters['pattern']; end
|
|
122
|
+
# Limit of request to Entrez : shortcuts for @parameters
|
|
123
|
+
def entrez_query; @parameters['entrez-query']; end
|
|
124
|
+
|
|
125
|
+
# Iterates on each Bio::Blast::Report::Iteration object. (for blastpgp)
|
|
126
|
+
def each_iteration
|
|
127
|
+
@iterations.each do |x|
|
|
128
|
+
yield x
|
|
129
|
+
end
|
|
130
|
+
end
|
|
125
131
|
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
attr_reader :hits, :statistics
|
|
135
|
-
attr_accessor :num, :message
|
|
132
|
+
# Iterates on each Bio::Blast::Report::Hit object of the the last Iteration.
|
|
133
|
+
# Shortcut for the last iteration's hits (for blastall)
|
|
134
|
+
def each_hit
|
|
135
|
+
@iterations.last.each do |x|
|
|
136
|
+
yield x
|
|
137
|
+
end
|
|
138
|
+
end
|
|
139
|
+
alias each each_hit
|
|
136
140
|
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
end
|
|
141
|
+
# Returns a Array of Bio::Blast::Report::Hits of the last iteration.
|
|
142
|
+
# Shortcut for the last iteration's hits
|
|
143
|
+
def hits
|
|
144
|
+
@iterations.last.hits
|
|
145
|
+
end
|
|
143
146
|
|
|
147
|
+
# Returns a Hash containing execution statistics of the last iteration.
|
|
148
|
+
# Valid keys are:
|
|
149
|
+
# 'db-num', 'db-len', 'hsp-len', 'eff-space', 'kappa', 'lambda', 'entropy'
|
|
150
|
+
# Shortcut for the last iteration's statistics.
|
|
151
|
+
def statistics
|
|
152
|
+
@iterations.last.statistics
|
|
153
|
+
end
|
|
144
154
|
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
155
|
+
# Number of sequences in BLAST db
|
|
156
|
+
def db_num; statistics['db-num']; end
|
|
157
|
+
# Length of BLAST db
|
|
158
|
+
def db_len; statistics['db-len']; end
|
|
159
|
+
# Effective HSP length
|
|
160
|
+
def hsp_len; statistics['hsp-len']; end
|
|
161
|
+
# Effective search space
|
|
162
|
+
def eff_space; statistics['eff-space']; end
|
|
163
|
+
# Karlin-Altschul parameter K
|
|
164
|
+
def kappa; statistics['kappa']; end
|
|
165
|
+
# Karlin-Altschul parameter Lamba
|
|
166
|
+
def lambda; statistics['lambda']; end
|
|
167
|
+
# Karlin-Altschul parameter H
|
|
168
|
+
def entropy; statistics['entropy']; end
|
|
169
|
+
|
|
170
|
+
# Returns a String (or nil) containing execution message of the last
|
|
171
|
+
# iteration (typically "CONVERGED").
|
|
172
|
+
# Shortcut for the last iteration's message (for checking 'CONVERGED')
|
|
173
|
+
def message
|
|
174
|
+
@iterations.last.message
|
|
175
|
+
end
|
|
159
176
|
|
|
160
|
-
# Compatible with Bio::Fasta::Report::Hit
|
|
161
177
|
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
178
|
+
# Bio::Blast::Report::Iteration
|
|
179
|
+
class Iteration
|
|
180
|
+
def initialize
|
|
181
|
+
@message = nil
|
|
182
|
+
@statistics = {}
|
|
183
|
+
@num = 1
|
|
184
|
+
@hits = []
|
|
185
|
+
end
|
|
186
|
+
# Returns an Array of Bio::Blast::Report::Hit objects.
|
|
187
|
+
attr_reader :hits
|
|
165
188
|
|
|
166
|
-
|
|
189
|
+
# Returns a Hash containing execution statistics.
|
|
190
|
+
# Valid keys are:
|
|
191
|
+
# 'db-len', 'db-num', 'eff-space', 'entropy', 'hsp-len', 'kappa', 'lambda'
|
|
192
|
+
attr_reader :statistics
|
|
167
193
|
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
def identity; @hsps.first.identity; end
|
|
171
|
-
def percent_identity; @hsps.first.percent_identity; end
|
|
172
|
-
def overlap; @hsps.first.align_len; end
|
|
194
|
+
# Returns the number of iteration counts.
|
|
195
|
+
attr_accessor :num
|
|
173
196
|
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
197
|
+
# Returns a String (or nil) containing execution message (typically
|
|
198
|
+
# "CONVERGED").
|
|
199
|
+
attr_accessor :message
|
|
177
200
|
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
def lap_at
|
|
183
|
-
[ query_start, query_end, target_start, target_end ]
|
|
184
|
-
end
|
|
201
|
+
# Iterates on each Bio::Blast::Report::Hit object.
|
|
202
|
+
def each
|
|
203
|
+
@hits.each do |x|
|
|
204
|
+
yield x
|
|
185
205
|
end
|
|
206
|
+
end
|
|
207
|
+
end
|
|
186
208
|
|
|
187
209
|
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
210
|
+
# Bio::Blast::Report::Hit
|
|
211
|
+
class Hit
|
|
212
|
+
def initialize
|
|
213
|
+
@hsps = []
|
|
214
|
+
end
|
|
215
|
+
|
|
216
|
+
# Returns an Array of Bio::Blast::Report::Hsp objects.
|
|
217
|
+
attr_reader :hsps
|
|
218
|
+
|
|
219
|
+
# Hit number
|
|
220
|
+
attr_accessor :num
|
|
221
|
+
# SeqId of subject
|
|
222
|
+
attr_accessor :hit_id
|
|
223
|
+
# Length of subject
|
|
224
|
+
attr_accessor :len
|
|
225
|
+
# Definition line of subject
|
|
226
|
+
attr_accessor :definition
|
|
227
|
+
# Accession
|
|
228
|
+
attr_accessor :accession
|
|
229
|
+
|
|
230
|
+
# Iterates on each Hsp object.
|
|
231
|
+
def each
|
|
232
|
+
@hsps.each do |x|
|
|
233
|
+
yield x
|
|
200
234
|
end
|
|
235
|
+
end
|
|
201
236
|
|
|
237
|
+
# Compatible method with Bio::Fasta::Report::Hit class.
|
|
238
|
+
attr_accessor :query_id
|
|
239
|
+
# Compatible method with Bio::Fasta::Report::Hit class.
|
|
240
|
+
attr_accessor :query_def
|
|
241
|
+
# Compatible method with Bio::Fasta::Report::Hit class.
|
|
242
|
+
attr_accessor :query_len
|
|
243
|
+
|
|
244
|
+
# Compatible method with Bio::Fasta::Report::Hit class.
|
|
245
|
+
alias target_id accession
|
|
246
|
+
# Compatible method with Bio::Fasta::Report::Hit class.
|
|
247
|
+
alias target_def definition
|
|
248
|
+
# Compatible method with Bio::Fasta::Report::Hit class.
|
|
249
|
+
alias target_len len
|
|
250
|
+
|
|
251
|
+
# Shortcut methods for the best Hsp, some are also compatible with
|
|
252
|
+
# Bio::Fasta::Report::Hit class.
|
|
253
|
+
def evalue; @hsps.first.evalue; end
|
|
254
|
+
def bit_score; @hsps.first.bit_score; end
|
|
255
|
+
def identity; @hsps.first.identity; end
|
|
256
|
+
def percent_identity; @hsps.first.percent_identity; end
|
|
257
|
+
def overlap; @hsps.first.align_len; end
|
|
258
|
+
|
|
259
|
+
def query_seq; @hsps.first.qseq; end
|
|
260
|
+
def target_seq; @hsps.first.hseq; end
|
|
261
|
+
def midline; @hsps.first.midline; end
|
|
262
|
+
|
|
263
|
+
def query_start; @hsps.first.query_from; end
|
|
264
|
+
def query_end; @hsps.first.query_to; end
|
|
265
|
+
def target_start; @hsps.first.hit_from; end
|
|
266
|
+
def target_end; @hsps.first.hit_to; end
|
|
267
|
+
def lap_at
|
|
268
|
+
[ query_start, query_end, target_start, target_end ]
|
|
202
269
|
end
|
|
203
270
|
end
|
|
204
|
-
|
|
271
|
+
|
|
272
|
+
|
|
273
|
+
# Bio::Blast::Report::Hsp
|
|
274
|
+
class Hsp
|
|
275
|
+
def initialize
|
|
276
|
+
@hsp = {}
|
|
277
|
+
end
|
|
278
|
+
attr_reader :hsp
|
|
279
|
+
|
|
280
|
+
# HSP number
|
|
281
|
+
attr_accessor :num
|
|
282
|
+
# Score (in bits) of HSP
|
|
283
|
+
attr_accessor :bit_score
|
|
284
|
+
# Sscore of HSP
|
|
285
|
+
attr_accessor :score
|
|
286
|
+
# E-value of HSP
|
|
287
|
+
attr_accessor :evalue
|
|
288
|
+
# Start of HSP in query
|
|
289
|
+
attr_accessor :query_from
|
|
290
|
+
# End of HSP
|
|
291
|
+
attr_accessor :query_to
|
|
292
|
+
# Start of HSP in subject
|
|
293
|
+
attr_accessor :hit_from
|
|
294
|
+
# End of HSP
|
|
295
|
+
attr_accessor :hit_to
|
|
296
|
+
# Start of PHI-BLAST pattern
|
|
297
|
+
attr_accessor :pattern_from
|
|
298
|
+
# End of PHI-BLAST pattern
|
|
299
|
+
attr_accessor :pattern_to
|
|
300
|
+
# Translation frame of query
|
|
301
|
+
attr_accessor :query_frame
|
|
302
|
+
# Translation frame of subject
|
|
303
|
+
attr_accessor :hit_frame
|
|
304
|
+
# Number of identities in HSP
|
|
305
|
+
attr_accessor :identity
|
|
306
|
+
# Number of positives in HSP
|
|
307
|
+
attr_accessor :positive
|
|
308
|
+
# Number of gaps in HSP
|
|
309
|
+
attr_accessor :gaps
|
|
310
|
+
# Length of the alignment used
|
|
311
|
+
attr_accessor :align_len
|
|
312
|
+
# Score density
|
|
313
|
+
attr_accessor :density
|
|
314
|
+
# Alignment string for the query (with gaps)
|
|
315
|
+
attr_accessor :qseq
|
|
316
|
+
# Alignment string for subject (with gaps)
|
|
317
|
+
attr_accessor :hseq
|
|
318
|
+
# Formating middle line
|
|
319
|
+
attr_accessor :midline
|
|
320
|
+
# Available only for '-m 8' format outputs.
|
|
321
|
+
attr_accessor :percent_identity
|
|
322
|
+
# Available only for '-m 8' format outputs.
|
|
323
|
+
attr_accessor :mismatch_count
|
|
324
|
+
end
|
|
325
|
+
|
|
326
|
+
end # Report
|
|
327
|
+
|
|
328
|
+
end # Blast
|
|
329
|
+
end # Bio
|
|
205
330
|
|
|
206
331
|
|
|
207
332
|
if __FILE__ == $0
|
|
@@ -389,264 +514,3 @@ if __FILE__ == $0
|
|
|
389
514
|
end
|
|
390
515
|
|
|
391
516
|
|
|
392
|
-
=begin
|
|
393
|
-
|
|
394
|
-
= Bio::Blast::Report
|
|
395
|
-
|
|
396
|
-
Parsed results of the blast execution for Tab-delimited and XML output
|
|
397
|
-
format. Tab-delimited reports are consists of
|
|
398
|
-
|
|
399
|
-
Query id,
|
|
400
|
-
Subject id,
|
|
401
|
-
percent of identity,
|
|
402
|
-
alignment length,
|
|
403
|
-
number of mismatches (not including gaps),
|
|
404
|
-
number of gap openings,
|
|
405
|
-
start of alignment in query,
|
|
406
|
-
end of alignment in query,
|
|
407
|
-
start of alignment in subject,
|
|
408
|
-
end of alignment in subject,
|
|
409
|
-
expected value,
|
|
410
|
-
bit score.
|
|
411
|
-
|
|
412
|
-
according to the MEGABLAST document (README.mbl). As for XML output,
|
|
413
|
-
see the following DTDs.
|
|
414
|
-
|
|
415
|
-
* http://www.ncbi.nlm.nih.gov/dtd/NCBI_BlastOutput.dtd
|
|
416
|
-
* http://www.ncbi.nlm.nih.gov/dtd/NCBI_BlastOutput.mod
|
|
417
|
-
* http://www.ncbi.nlm.nih.gov/dtd/NCBI_Entity.mod
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
--- Bio::Blast::Report.new(data)
|
|
421
|
-
|
|
422
|
-
Passing a BLAST output from 'blastall -m 7' or '-m 8' as a String.
|
|
423
|
-
Formats are auto detected.
|
|
424
|
-
|
|
425
|
-
--- Bio::Blast::Report.xmlparaser(xml)
|
|
426
|
-
|
|
427
|
-
Specify to use XMLParser to parse XML (-m 7) output.
|
|
428
|
-
|
|
429
|
-
--- Bio::Blast::Report.rexml(xml)
|
|
430
|
-
|
|
431
|
-
Specify to use REXML to parse XML (-m 7) output.
|
|
432
|
-
|
|
433
|
-
--- Bio::Blast::Report.tab(data)
|
|
434
|
-
|
|
435
|
-
Specify to use tab delimited output parser.
|
|
436
|
-
|
|
437
|
-
--- Bio::Blast::Report#program
|
|
438
|
-
--- Bio::Blast::Report#version
|
|
439
|
-
--- Bio::Blast::Report#reference
|
|
440
|
-
--- Bio::Blast::Report#db
|
|
441
|
-
--- Bio::Blast::Report#query_id
|
|
442
|
-
--- Bio::Blast::Report#query_def
|
|
443
|
-
--- Bio::Blast::Report#query_len
|
|
444
|
-
|
|
445
|
-
Shortcut for BlastOutput values.
|
|
446
|
-
|
|
447
|
-
--- Bio::Blast::Report#parameters
|
|
448
|
-
|
|
449
|
-
Returns a Hash containing execution parameters. Valid keys are:
|
|
450
|
-
'matrix', 'expect', 'include', 'sc-match', 'sc-mismatch',
|
|
451
|
-
'gap-open', 'gap-extend', 'filter'
|
|
452
|
-
|
|
453
|
-
--- Bio::Blast::Report#matrix
|
|
454
|
-
* Matrix used (-M)
|
|
455
|
-
--- Bio::Blast::Report#expect
|
|
456
|
-
* Expectation threshold (-e)
|
|
457
|
-
--- Bio::Blast::Report#inclusion
|
|
458
|
-
* Inclusion threshold (-h)
|
|
459
|
-
--- Bio::Blast::Report#sc_match
|
|
460
|
-
* Match score for NT (-r)
|
|
461
|
-
--- Bio::Blast::Report#sc_mismatch
|
|
462
|
-
* Mismatch score for NT (-q)
|
|
463
|
-
--- Bio::Blast::Report#gap_open
|
|
464
|
-
* Gap opening cost (-G)
|
|
465
|
-
--- Bio::Blast::Report#gap_extend
|
|
466
|
-
* Gap extension cost (-E)
|
|
467
|
-
--- Bio::Blast::Report#filter
|
|
468
|
-
* Filtering options (-F)
|
|
469
|
-
--- Bio::Blast::Report#pattern
|
|
470
|
-
* PHI-BLAST pattern
|
|
471
|
-
--- Bio::Blast::Report#entrez_query
|
|
472
|
-
* Limit of request to Entrez
|
|
473
|
-
|
|
474
|
-
These are shortcuts for parameters.
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
--- Bio::Blast::Report#iterations
|
|
478
|
-
|
|
479
|
-
Returns an Array of Bio::Blast::Report::Iteration objects.
|
|
480
|
-
|
|
481
|
-
--- Bio::Blast::Report#each_iteration
|
|
482
|
-
|
|
483
|
-
Iterates on each Bio::Blast::Report::Iteration object.
|
|
484
|
-
|
|
485
|
-
--- Bio::Blast::Report#each_hit
|
|
486
|
-
--- Bio::Blast::Report#each
|
|
487
|
-
|
|
488
|
-
Iterates on each Bio::Blast::Report::Hit object of the the
|
|
489
|
-
last Iteration.
|
|
490
|
-
|
|
491
|
-
--- Bio::Blast::Report#statistics
|
|
492
|
-
|
|
493
|
-
Returns a Hash containing execution statistics of the last iteration.
|
|
494
|
-
Valid keys are:
|
|
495
|
-
'db-num', 'db-len', 'hsp-len', 'eff-space', 'kappa',
|
|
496
|
-
'lambda', 'entropy'
|
|
497
|
-
|
|
498
|
-
--- Bio::Blast::Report#db_num
|
|
499
|
-
* Number of sequences in BLAST db
|
|
500
|
-
--- Bio::Blast::Report#db_len
|
|
501
|
-
* Length of BLAST db
|
|
502
|
-
--- Bio::Blast::Report#hsp_len
|
|
503
|
-
* Effective HSP length
|
|
504
|
-
--- Bio::Blast::Report#eff_space
|
|
505
|
-
* Effective search space
|
|
506
|
-
--- Bio::Blast::Report#kappa
|
|
507
|
-
* Karlin-Altschul parameter K
|
|
508
|
-
--- Bio::Blast::Report#lambda
|
|
509
|
-
* Karlin-Altschul parameter Lamba
|
|
510
|
-
--- Bio::Blast::Report#entropy
|
|
511
|
-
* Karlin-Altschul parameter H
|
|
512
|
-
|
|
513
|
-
These are shortcuts for statistics.
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
--- Bio::Blast::Report#message
|
|
517
|
-
|
|
518
|
-
Returns a String (or nil) containing execution message of the last
|
|
519
|
-
iteration (typically "CONVERGED").
|
|
520
|
-
|
|
521
|
-
--- Bio::Blast::Report#hits
|
|
522
|
-
|
|
523
|
-
Returns a Array of Bio::Blast::Report::Hits of the last iteration.
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
== Bio::Blast::Report::Iteration
|
|
527
|
-
|
|
528
|
-
--- Bio::Blast::Report::Iteration#num
|
|
529
|
-
|
|
530
|
-
Returns the number of iteration counts.
|
|
531
|
-
|
|
532
|
-
--- Bio::Blast::Report::Iteration#hits
|
|
533
|
-
|
|
534
|
-
Returns an Array of Bio::Blast::Report::Hit objects.
|
|
535
|
-
|
|
536
|
-
--- Bio::Blast::Report::Iteration#each
|
|
537
|
-
|
|
538
|
-
Iterates on each Bio::Blast::Report::Hit object.
|
|
539
|
-
|
|
540
|
-
--- Bio::Blast::Report::Iteration#statistics
|
|
541
|
-
|
|
542
|
-
Returns a Hash containing execution statistics.
|
|
543
|
-
Valid keys are:
|
|
544
|
-
'db-len', 'db-num', 'eff-space', 'entropy', 'hsp-len',
|
|
545
|
-
'kappa', 'lambda'
|
|
546
|
-
|
|
547
|
-
--- Bio::Blast::Report::Iteration#message
|
|
548
|
-
|
|
549
|
-
Returns a String (or nil) containing execution message (typically
|
|
550
|
-
"CONVERGED").
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
== Bio::Blast::Report::Hit
|
|
554
|
-
|
|
555
|
-
--- Bio::Blast::Report::Hit#each
|
|
556
|
-
|
|
557
|
-
Iterates on each Hsp object.
|
|
558
|
-
|
|
559
|
-
--- Bio::Blast::Report::Hit#hsps
|
|
560
|
-
|
|
561
|
-
Returns an Array of Bio::Blast::Report::Hsp objects.
|
|
562
|
-
|
|
563
|
-
--- Bio::Blast::Report::Hit#num
|
|
564
|
-
* hit number
|
|
565
|
-
--- Bio::Blast::Report::Hit#hit_id
|
|
566
|
-
* SeqId of subject
|
|
567
|
-
--- Bio::Blast::Report::Hit#len
|
|
568
|
-
* length of subject
|
|
569
|
-
--- Bio::Blast::Report::Hit#definition
|
|
570
|
-
* definition line of subject
|
|
571
|
-
--- Bio::Blast::Report::Hit#accession
|
|
572
|
-
* accession
|
|
573
|
-
|
|
574
|
-
Accessors for the Hit values.
|
|
575
|
-
|
|
576
|
-
--- Bio::Blast::Report::Hit#query_id
|
|
577
|
-
--- Bio::Blast::Report::Hit#query_def
|
|
578
|
-
--- Bio::Blast::Report::Hit#query_len
|
|
579
|
-
--- Bio::Blast::Report::Hit#target_id
|
|
580
|
-
--- Bio::Blast::Report::Hit#target_def
|
|
581
|
-
--- Bio::Blast::Report::Hit#target_len
|
|
582
|
-
|
|
583
|
-
Compatible methods with Bio::Fasta::Report::Hit class.
|
|
584
|
-
|
|
585
|
-
--- Bio::Blast::Report::Hit#evalue
|
|
586
|
-
--- Bio::Blast::Report::Hit#bit_score
|
|
587
|
-
--- Bio::Blast::Report::Hit#identity
|
|
588
|
-
--- Bio::Blast::Report::Hit#overlap
|
|
589
|
-
|
|
590
|
-
--- Bio::Blast::Report::Hit#query_seq
|
|
591
|
-
--- Bio::Blast::Report::Hit#midline
|
|
592
|
-
--- Bio::Blast::Report::Hit#target_seq
|
|
593
|
-
|
|
594
|
-
--- Bio::Blast::Report::Hit#query_start
|
|
595
|
-
--- Bio::Blast::Report::Hit#query_end
|
|
596
|
-
--- Bio::Blast::Report::Hit#target_start
|
|
597
|
-
--- Bio::Blast::Report::Hit#target_end
|
|
598
|
-
--- Bio::Blast::Report::Hit#lap_at
|
|
599
|
-
|
|
600
|
-
Shortcut methods for the best Hsp, some are also compatible with
|
|
601
|
-
Bio::Fasta::Report::Hit class.
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
== Bio::Blast::Report::Hsp
|
|
605
|
-
|
|
606
|
-
--- Bio::Blast::Report::Hsp#num
|
|
607
|
-
* HSP number
|
|
608
|
-
--- Bio::Blast::Report::Hsp#bit_score
|
|
609
|
-
* score (in bits) of HSP
|
|
610
|
-
--- Bio::Blast::Report::Hsp#score
|
|
611
|
-
* score of HSP
|
|
612
|
-
--- Bio::Blast::Report::Hsp#evalue
|
|
613
|
-
* e-value of HSP
|
|
614
|
-
--- Bio::Blast::Report::Hsp#query_from
|
|
615
|
-
* start of HSP in query
|
|
616
|
-
--- Bio::Blast::Report::Hsp#query_to
|
|
617
|
-
* end of HSP
|
|
618
|
-
--- Bio::Blast::Report::Hsp#hit_from
|
|
619
|
-
* start of HSP in subject
|
|
620
|
-
--- Bio::Blast::Report::Hsp#hit_to
|
|
621
|
-
* end of HSP
|
|
622
|
-
--- Bio::Blast::Report::Hsp#pattern_from
|
|
623
|
-
* start of PHI-BLAST pattern
|
|
624
|
-
--- Bio::Blast::Report::Hsp#pattern_to
|
|
625
|
-
* end of PHI-BLAST pattern
|
|
626
|
-
--- Bio::Blast::Report::Hsp#query_frame
|
|
627
|
-
* translation frame of query
|
|
628
|
-
--- Bio::Blast::Report::Hsp#hit_frame
|
|
629
|
-
* translation frame of subject
|
|
630
|
-
--- Bio::Blast::Report::Hsp#identity
|
|
631
|
-
* number of identities in HSP
|
|
632
|
-
--- Bio::Blast::Report::Hsp#positive
|
|
633
|
-
* number of positives in HSP
|
|
634
|
-
--- Bio::Blast::Report::Hsp#gaps
|
|
635
|
-
* number of gaps in HSP
|
|
636
|
-
--- Bio::Blast::Report::Hsp#align_len
|
|
637
|
-
* length of the alignment used
|
|
638
|
-
--- Bio::Blast::Report::Hsp#density
|
|
639
|
-
* score density
|
|
640
|
-
--- Bio::Blast::Report::Hsp#qseq
|
|
641
|
-
* alignment string for the query (with gaps)
|
|
642
|
-
--- Bio::Blast::Report::Hsp#hseq
|
|
643
|
-
* alignment string for subject (with gaps)
|
|
644
|
-
--- Bio::Blast::Report::Hsp#midline
|
|
645
|
-
* formating middle line
|
|
646
|
-
|
|
647
|
-
--- Bio::Blast::Report::Hsp#percent_identity
|
|
648
|
-
--- Bio::Blast::Report::Hsp#mismatch_count
|
|
649
|
-
|
|
650
|
-
Available only for '-m 8' format outputs.
|
|
651
|
-
|
|
652
|
-
=end
|