class MS::Lipid::Search::Hit
Attributes
db_isobar_group[RW]
the db_isobar_group
this hit is associated with. Each hit is only associated with a single db_isobar_group
!
observed_mz[RW]
the experimental m/z value
probability_distribution[RW]
the probability distribution that can be used to determine its pvalue
pvalue[RW]
the probability the hit is due to random chance
qvalue[RW]
the FDR if the threshold accepts this pvalue. Note that this value is relative to the number of tests performed and not completely intrinsic to the hit itself.
Public Class Methods
new(hash={})
click to toggle source
# File lib/ms/lipid/search/hit.rb, line 22 def initialize(hash={}) hash.each {|k,v| instance_variable_set("@#{k}", v) } end
Public Instance Methods
delta()
click to toggle source
observed_mz
- query m/z
# File lib/ms/lipid/search/hit.rb, line 27 def delta @observed_mz - @db_isobar_group.first.mz.to_f end
Also aliased as: amu
delta_abs()
click to toggle source
the absolute value of distance from true val
# File lib/ms/lipid/search/hit.rb, line 34 def delta_abs delta.abs end
inspect()
click to toggle source
# File lib/ms/lipid/search/hit.rb, line 47 def inspect "<<#{super} -- <ppm=#{ppm} delta=#{delta} theoretical_mz=#{theoretical_mz}>>" end
ppm()
click to toggle source
parts per million (divided by theoretical m/z)
# File lib/ms/lipid/search/hit.rb, line 39 def ppm (delta / @db_isobar_group.first.mz) * 1e6 end
theoretical_mz()
click to toggle source
# File lib/ms/lipid/search/hit.rb, line 43 def theoretical_mz @db_isobar_group.first.mz end