Class: DRP::MaxDepths::MappedMaxDepth

Inherits:
Object
  • Object
show all
Defined in:
lib/weights_and_max_depths.rb

Instance Method Summary collapse

Constructor Details

#initialize(range, function = :i_linear) ⇒ MappedMaxDepth

Returns a new instance of MappedMaxDepth.



42
43
44
# File 'lib/weights_and_max_depths.rb', line 42

def initialize range, function = :i_linear
  @range, @function = range, function
end

Instance Method Details

#value(drp_instance) ⇒ Object



45
46
47
48
49
50
51
# File 'lib/weights_and_max_depths.rb', line 45

def value drp_instance
  Utils::map(
    @range,
    drp_instance.next_meta_codon,
    @function
  )
end