Class ExecutionAlgoBacktester
execution.BenchmarkExecutor (built for live intervals)
and the backtest lane: replay a session's bars, let the executor
re-decide each bar exactly as it would live, fill against the bar with
a TradeCostModel, and grade the result the way a TCA desk
would (implementation shortfall vs arrival, slippage vs the session
VWAP). ExecutionAwareBacktester answers "how do fills change a
strategy's results?"; this answers the execution desk's own question:
"which benchmark algorithm, and at what cost?" One parent
order, N bars, a number per benchmark.
Simplifications: fills
print at the bar close plus the cost model's bps (no intra-bar
microstructure). The per-bar liquidity cap is
participationCap × bar volume, and it is the only cap: the
executor is constructed with its internal depth fraction at 1 so the
two knobs cannot silently compound. The VWAP volume curve uses the
session's realized cumulative volume. That is an oracle curve, so the
VWAP benchmark result here is an upper bound on what a live
volume-curve forecast can achieve (live, use
microstructure.VolumeCurve). Each bar's volume enters the POV
target before that bar trades: one bar of look-ahead versus a strictly
reactive live POV, so POV completion here is mildly optimistic.
Deterministic: same bars, same config, same numbers. Research lane.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final recordExecution simulation settings.static final recordThe TCA-style verdict for one parent worked over one session. -
Constructor Summary
ConstructorsConstructorDescription -
Method Summary
Modifier and TypeMethodDescriptionrun(BarSeries series, Side side, long parentQty, BenchmarkExecutor.Benchmark benchmark) run(BarSeries, Side, long, BenchmarkExecutor.Benchmark, double)for the time/volume benchmarks (no POV rate needed).run(BarSeries series, Side side, long parentQty, BenchmarkExecutor.Benchmark benchmark, double povRate) WorksparentQtythrough the session underbenchmarkand grades it.
-
Constructor Details
-
ExecutionAlgoBacktester
-
ExecutionAlgoBacktester
public ExecutionAlgoBacktester()
-
-
Method Details
-
run
public ExecutionAlgoBacktester.Result run(BarSeries series, Side side, long parentQty, BenchmarkExecutor.Benchmark benchmark, double povRate) WorksparentQtythrough the session underbenchmarkand grades it. Participation parents useBenchmarkExecutor.pov(Side, long, double)withpovRate; other benchmarks ignore it. -
run
public ExecutionAlgoBacktester.Result run(BarSeries series, Side side, long parentQty, BenchmarkExecutor.Benchmark benchmark) run(BarSeries, Side, long, BenchmarkExecutor.Benchmark, double)for the time/volume benchmarks (no POV rate needed).
-