Class: SQA::Trade
- Inherits:
-
Object
- Object
- SQA::Trade
- Defined in:
- lib/sqa/trade.rb
Instance Attribute Summary collapse
-
#df ⇒ Object
Returns the value of attribute df.
Instance Method Summary collapse
- #confirm(uuid, shares, price) ⇒ Object
-
#initialize(filename = SQA::Config.trades_filename) ⇒ Trade
constructor
A new instance of Trade.
- #place(signal, ticker, shares, price = nil) ⇒ Object
- #save ⇒ Object
Constructor Details
Instance Attribute Details
#df ⇒ Object
Returns the value of attribute df.
5 6 7 |
# File 'lib/sqa/trade.rb', line 5 def df @df end |
Instance Method Details
#confirm(uuid, shares, price) ⇒ Object
19 20 21 |
# File 'lib/sqa/trade.rb', line 19 def confirm(uuid, shares, price) # TODO: update the row in the data frame end |
#place(signal, ticker, shares, price = nil) ⇒ Object
13 14 15 16 17 |
# File 'lib/sqa/trade.rb', line 13 def place(signal, ticker, shares, price=nil) # TODO: insert row into @df uuid = rand(100000) # FIXME: place holder end |
#save ⇒ Object
23 24 25 |
# File 'lib/sqa/trade.rb', line 23 def save # TODO: save the data frame end |