Class: Statkit::Spec::MaxFuncExp
- Defined in:
- lib/statkit/specexp.rb
Instance Method Summary collapse
- #add_input_chunk(input_chunk) ⇒ Object
- #evaluate ⇒ Object
-
#initialize ⇒ MaxFuncExp
constructor
A new instance of MaxFuncExp.
- #streaming? ⇒ Boolean
Methods inherited from BaseExp
Constructor Details
#initialize ⇒ MaxFuncExp
Returns a new instance of MaxFuncExp.
95 96 97 |
# File 'lib/statkit/specexp.rb', line 95 def initialize @max = nil end |
Instance Method Details
#add_input_chunk(input_chunk) ⇒ Object
103 104 105 106 107 108 109 |
# File 'lib/statkit/specexp.rb', line 103 def add_input_chunk(input_chunk) if @max.nil? @max = input_chunk.max else @max = (input_chunk + [@max]).max end end |
#evaluate ⇒ Object
111 112 113 |
# File 'lib/statkit/specexp.rb', line 111 def evaluate() @max end |
#streaming? ⇒ Boolean
99 100 101 |
# File 'lib/statkit/specexp.rb', line 99 def streaming? true end |