class Bio::HMMER::Report::Hit
Container class for HMMER
search hits.
Attributes
Matching scores (total of all HSPs).
E-value
An Array of Bio::HMMER::Report::Hsp
objects.
Number of domains
Matching scores (total of all HSPs).
Public Class Methods
Source
# File lib/bio/appl/hmmer/report.rb 391 def initialize(hit_data) 392 @hsps = Array.new 393 if /^(\S+)\s+(.*?)\s+(\S+)\s+(\S+)\s+(\S+)$/ =~ hit_data 394 @accession, @description, @score, @evalue, @num = \ 395 [$1, $2, $3.to_f, $4.to_f, $5.to_i] 396 end 397 end
Sets hit data.
Public Instance Methods
Source
# File lib/bio/appl/hmmer/report.rb 419 def append_hsp(hsp) 420 @hsps << hsp 421 end
Appends a Bio::HMMER::Report::Hsp
object.
Source
# File lib/bio/appl/hmmer/report.rb 401 def each 402 @hsps.each do |hsp| 403 yield hsp 404 end 405 end
Iterates on each Hsp
object (Bio::HMMER::Report::Hsp
).
Also aliased as: each_hsp
Source
# File lib/bio/appl/hmmer/report.rb 410 def target_def 411 if @hsps.size == 1 412 "<#{@hsps[0].domain}> #{@description}" 413 else 414 "<#{@num.to_s}> #{@description}" 415 end 416 end
Shows the hit description.