OptionalfeeFixed fee (or rebate when negative) charged per contract on each fill.
OptionalinitialStarting capital for size="weight" and for rebalance_band; equity is initial_capital plus the backtest's cumulative pnl.
OptionalmaxUpper bound on the position, in units. It applies after size has converted the target to units, so a weight target of 2 with max_position=0.5 holds 0.5 units. The default, inf, is no bound.
OptionalminLower bound on the position, in units. It applies after size has converted the target to units, so a weight target of -2 with min_position=-0.5 holds -0.5 units. The default, -inf, is no bound.
OptionalmultiplierContract multiplier applied to mark-to-market PnL, fill slippage, and proportional fees.
OptionalrebalanceWith size="notional" or "weight", recompute the units when the holding drifts from the target by more than this fraction of equity (0.05 = 5 points of weight). 0 keeps the units until the target value changes.
OptionalsizeHow to read the target: "units" (a position), "notional" (a currency amount), or "weight" (a fraction of initial_capital + equity). It is converted to units at the execution price.
OptionalslippageAdverse price offset on every taker (market) fill, read in slippage_unit. A buy fills higher and a sell lower; resting limit fills never slip.
OptionalslippageUnit of slippage: "fraction" of the reference price (5 bps = 5e-4), "ticks" of tick_size, or "price" (an absolute amount).
OptionalstopExit when the price moves this fraction against the average entry fill (0.05 = 5%). 0 turns it off.
OptionaltakeExit when the price moves this fraction in favor of the average entry fill. 0 turns it off.
OptionaltakerFractional fee charged on each taker fill.
OptionaltickInstrument price grid (0 = continuous). A marketable order walks one tick past the displayed quote for the size beyond it; slippage offsets round up to whole ticks.
OptionaltrailingExit when the price falls this fraction from the best price since entry (the highest for a long, the lowest for a short). 0 turns it off.
The settings of BacktestL1Target by name, for
BacktestL1Target({ ... }).