docs/concepts/instruments/equity.md
Equity represents a listed share, ETF, or similar cash-market security. Nautilus uses
this type for instruments that trade in whole units, quote in one currency, and have no
contract expiry.
Examples include AAPL.XNAS, MSFT.XNAS, and venue-specific ETF symbols.
| Field | Rust type | Python type | Required/default | Notes |
|---|---|---|---|---|
instrument_id | InstrumentId | InstrumentId | Required | Stored as id in Rust. |
raw_symbol | Symbol | Symbol | Required | Native venue symbol. |
currency | Currency | Currency | Required | Quote and settlement currency. |
price_precision | u8 | int | Required | Decimal places allowed for prices. |
price_increment | Price | Price | Required | Smallest valid price step. |
lot_size | Option<Quantity> | Quantity | Required/Python | Board lot or whole‑share lot size. |
ts_event | UnixNanos | int | Required | Event timestamp in nanoseconds. |
ts_init | UnixNanos | int | Required | Initialization timestamp in nanoseconds. |
isin | Option<Ustr> | str | None | None | International Securities ID when known. |
max_quantity | Option<Quantity> | Quantity | None | None | Maximum order quantity. |
min_quantity | Option<Quantity> | Quantity | None | None | Minimum order quantity. |
max_price | Option<Price> | N/A | Rust only | Maximum valid quote or order price. |
min_price | Option<Price> | N/A | Rust only | Minimum valid quote or order price. |
margin_init | Option<Decimal> | Decimal | None | 0 | Initial margin rate. |
margin_maint | Option<Decimal> | Decimal | None | 0 | Maintenance margin rate. |
maker_fee | Option<Decimal> | Decimal | None | 0 | Maker fee rate. Negative values rebate. |
taker_fee | Option<Decimal> | Decimal | None | 0 | Taker fee rate. Negative values rebate. |
tick_scheme_name | N/A | str | None | None | Registered variable tick scheme name. |
info | Option<Params> | dict | None | None | Adapter metadata. |
Note: Python constructors use instrument_id; Rust stores the same value as id.
Equity has asset class Equity and instrument class Spot.use nautilus_core::UnixNanos;
use nautilus_model::{
identifiers::{InstrumentId, Symbol},
instruments::Equity,
types::{Currency, Price, Quantity},
};
use ustr::Ustr;
let aapl = Equity::new(
InstrumentId::from("AAPL.XNAS"),
Symbol::from("AAPL"),
Some(Ustr::from("US0378331005")),
Currency::from("USD"),
2,
Price::from("0.01"),
Some(Quantity::from("100")),
None,
None,
None,
None,
None,
None,
None,
None,
None,
UnixNanos::default(),
UnixNanos::default(),
);
from nautilus_trader.model.currencies import USD
from nautilus_trader.model.identifiers import InstrumentId
from nautilus_trader.model.identifiers import Symbol
from nautilus_trader.model.instruments import Equity
from nautilus_trader.model.objects import Price
from nautilus_trader.model.objects import Quantity
aapl = Equity(
instrument_id=InstrumentId.from_str("AAPL.XNAS"),
raw_symbol=Symbol("AAPL"),
isin="US0378331005",
currency=USD,
price_precision=2,
price_increment=Price.from_str("0.01"),
lot_size=Quantity.from_int(100),
ts_event=0,
ts_init=0,
)
Representative adapters that create or consume Equity instruments include:
Price, Quantity, and Money.