Class: OptionLab::Models::EngineDataResults

Inherits:
BaseModel
  • Object
show all
Defined in:
lib/option_lab/models.rb

Overview

Engine data results for access after calculations

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(attributes = {}) ⇒ EngineDataResults

Returns a new instance of EngineDataResults.



152
153
154
155
156
157
# File 'lib/option_lab/models.rb', line 152

def initialize(attributes = {})
  @stock_price_array = Numo::DFloat.new(0)
  @strategy_profit = Numo::DFloat.new(0)
  @profit = []
  super(attributes)
end

Instance Attribute Details

#profitObject

Returns the value of attribute profit.



150
151
152
# File 'lib/option_lab/models.rb', line 150

def profit
  @profit
end

#stock_price_arrayObject

Returns the value of attribute stock_price_array.



150
151
152
# File 'lib/option_lab/models.rb', line 150

def stock_price_array
  @stock_price_array
end

#strategy_profitObject

Returns the value of attribute strategy_profit.



150
151
152
# File 'lib/option_lab/models.rb', line 150

def strategy_profit
  @strategy_profit
end