pub fn parse_trade_tick(
instrument_id: InstrumentId,
price: f64,
size: f64,
price_precision: u8,
size_precision: u8,
ts_event: UnixNanos,
ts_init: UnixNanos,
trade_id: Option<TradeId>,
) -> Result<TradeTick>Expand description
Parse IB trade tick data into a TradeTick.
§Arguments
instrument_id- The instrument identifierprice- Trade pricesize- Trade sizeprice_precision- Price precision for the instrumentsize_precision- Size precision for the instrumentts_event- Event timestampts_init- Initialization timestamptrade_id- Optional trade ID (will be generated if not provided)
§Errors
Returns an error if price or size conversion fails.