Skip to main content

load_options_chain

Function load_options_chain 

Source
pub fn load_options_chain<P: AsRef<Path>>(
    filepath: P,
    underlyings: Option<Vec<String>>,
    price_precision: Option<u8>,
    size_precision: Option<u8>,
    limit: Option<usize>,
) -> Result<Vec<Data>, Box<dyn Error>>
Expand description

Loads option chain rows from a Tardis options_chain CSV file.

Returns quote ticks before option greeks for rows with a complete best bid/offer. Rows missing any best bid/offer field still return option greeks.

ยงErrors

Returns an error if the file cannot be opened, read, or parsed as CSV, or if a complete best bid/offer row contains invalid price or size values.