Skip to main content
strategy_parameters is optional; passing it records the parameter set alongside each result so you can line up results with param_sets afterwards. Each item in results is an ExecutionResult carrying the finished strategy.
Sweeps share one datafeedEvery strategy in the list is driven by the same environment, so the prepared data is opened once and the memory-mapped snapshots are shared across the whole sweep rather than re-read per run. Pass datafeed= and resolver= if you want to build them yourself.

Compare the results

Overlay the equity curves to read the sweep at a glance:
To rank by a metric, read each r.strategy.stats (see Metrics and Stats), for example sorted(results, key=lambda r: r.strategy.stats.annualized_sharpe_ratio, reverse=True).
Sweeps invite overfittingPicking the best parameter in-sample tells you little about the future. Hold out a period, or use walk-forward windows, before trusting a “best” setting.
Related: Reading results · Charts · Metrics and Stats
Last modified on November 4, 2026