Ticker
Market data returned by exchange.GetTicker(): high, low, best ask, best bid, last price, open, volume and open interest.
Attributes
| Name | Type | Description |
Info | object | Raw data returned by the exchange API, not included in backtesting. |
Symbol | string | The FMZ symbol, written as described in |
High | number | Highest price. May be 0 if the exchange API does not provide the 24-hour high; some exchanges approximate it with the best ask price. |
Low | number | Lowest price. May be 0 if the exchange API does not provide the 24-hour low; some exchanges approximate it with the best bid price. |
Sell | number | Current best ask price. Some exchanges' ticker endpoints carry no order book data, in which case it is 0; use |
Buy | number | Current best bid price. It is 0 when the exchange's ticker endpoint carries no order book data. |
Last | number | Last traded price. |
Open | number | Period opening price. May be 0 if the exchange API does not provide the opening price for the 24-hour rolling period. |
Volume | number | Recent trading volume. In principle, spot trading volume is in base currency units, and contract trading volume is in contract units. If the exchange API does not provide such data, it is filled with available data from the exchange API, for example, it may be trading volume in quote currency units. |
Time | number | Timestamp in milliseconds. |
OpenInterest | number | Open interest. Most exchange APIs do not provide this data, and the value is 0 when not supported. |
See Also
Remarks
The exchange.GetTicker() function returns a Ticker structure.
For option contracts, the order book is usually thin and there are often no orders on the bid or ask side; in that case the Buy and Sell fields of the Ticker structure are 0, and Last may also be 0 for an option that has never traded. Some exchanges report the mark price as Last (always, or only when there is no last trade price); see the "Options" and "Notes" sections of each exchange page. Check these fields before using option market data.