class IB::Bar
This is a single data point delivered by HistoricData or RealTimeBar messages. Instantiate with a Hash of attributes, to be auto-set via initialize in Model
.
Public Instance Methods
==(other)
click to toggle source
Order
comparison
Calls superclass method
IB::BaseProperties#==
# File lib/models/ib/bar.rb, line 25 def == other super(other) || other.is_a?(self.class) && time == other.time && open == other.open && high == other.high && low == other.low && close == other.close && wap == other.wap && trades == other.trades && volume == other.volume end
to_human()
click to toggle source
# File lib/models/ib/bar.rb, line 38 def to_human "<Bar: #{time} wap #{wap} OHLC #{open} #{high} #{low} #{close} " + (trades ? "trades #{trades}" : "") + " vol #{volume} gaps #{has_gaps}>" end
Also aliased as: to_s