Skip to main content

Backtesting

HyperionX runs historical strategy backtests through Validator. A backtest replays loaded historical candles using the selected strategy, data-series settings, fill model, commission model, leverage, and position-sizing behavior.

Backtesting is research, not a forecast of live performance. Historical candles cannot reproduce queue position, market impact, disconnected sessions, or every intrabar price path.

Verify the installed research components

The project changelog records product-owned research defaults in signed release 1.1.11 and a signed 1.1.12 MSI containing the validated Python Research Runtime. This documentation audit did not independently test the distributed MSI. Verify its signature, confirm Help > About, and make sure the required modules appear after first-launch compilation. A missing module is an installation or discovery problem; do not copy one from an untrusted source as a workaround. See Install, Update, And Uninstall.

Before You Start

You need:

  • A strategy that compiles in Code Lab.
  • An instrument and data series.
  • Historical candles for every Validator item you plan to run.
  • A strategy assigned to each item, or one strategy applied to all items.
  • The intended commission selection. If expected packaged modules do not appear after first-launch compilation, stop and collect diagnostics.
  • Valid strategy parameters and quantity or money-management settings.

Validator does not download or infer every missing input when you press Run. An item without loaded candles prevents the relevant test from starting.

Run A Historical Backtest

  1. Open Validator.
  2. Select Add instrument for one test, or Add test set for a saved group.
  3. Choose the instrument, connection, bar type, interval, and historical date range.
  4. Load historical candles for every item.
  5. Select a compiled strategy.
  6. Apply that strategy to the current item, or use Apply all when the same strategy and preset should be used across the set.
  7. Review the strategy parameters, commission, backtest leverage, historical fill model, and continuous-futures merge setting where applicable.
  8. Select Run.
  9. Review the aggregate result and each instrument result.
  10. Export the summary or save the strategy/test preset when you need to repeat the setup.

Validator can cancel an active run. Completed Validator results are also saved to the performance-results store.

Historical Fill Models

HyperionX currently provides two candle-based historical fill models:

Fill modelBehavior
OHLC stop-firstUses candle OHLC information and resolves an ambiguous stop/target candle in favor of the stop.
OHLC virtual pathUses a virtual path through the candle to determine the assumed order of intrabar prices.

Both are approximations. If a candle touches a stop and target, the selected model can materially change the result. Record the selected fill model when comparing runs.

Slippage And Liquidity

Treat the signed public 1.1.12 contract as not providing a documented configurable slippage model for ordinary Validator or Optimizer runs; the project changelog classifies the newer setting as Unreleased. Do not describe a 1.1.12 historical result as slippage-adjusted unless the strategy or a separate research workflow explicitly applies that cost.

Unreleased source version 1.1.14 adds a Validator-only adverse tick-slippage setting for historical Market and StopMarket fills; historical Limit fills remain unchanged. That development behavior is not part of the signed 1.1.12 release and does not add an Optimizer slippage control. Do not document or rely on it as shipped until a matching signed public release is published and verified.

Commission is modeled through the selected commission module when that module is available. Commission is not the same as slippage, spread, queue position, partial fills, or market impact.

Strategies that depend on tick-level ordering, very small targets, or high turnover need additional playback and simulation testing.

Review The Result

Review more than net profit:

  • Total trades and average trade.
  • Gross profit and gross loss.
  • Max drawdown.
  • Profit factor.
  • Sharpe and Sortino values where available.
  • Win rate and long/short contribution.
  • Consecutive wins and losses.
  • Commission.
  • Instrument contribution in a portfolio test.
  • Ambiguous fills and the selected historical fill model.

Use Find Improvements as a research aid, not as proof that a strategy is robust. Re-run changed settings and keep out-of-sample dates separate from the data used to choose parameters.

Move Beyond Historical Testing

HyperionX separates these stages:

StageWhat it checks
Historical backtestStrategy behavior against stored candles under the selected historical assumptions.
PlaybackReal-time-style strategy behavior while historical activity is replayed.
SimulationCurrent platform and connection behavior without intentionally routing to a live account.
Small live testReal execution behavior with tightly controlled risk.

For playback or simulation, explicitly select the intended LocalPaper or other non-live account. Playback does not change the selected account. Build-specific external-account guards are defense in depth, not a substitute for selecting and verifying LocalPaper before starting playback.

Save Enough Context

The saved performance record is useful for browsing and reopening results, but it is not currently a complete reproducibility package. Keep a separate record of strategy parameters, starting capital, commission configuration, and any assumptions that are not preserved by the results database.

See Performance Database for the exact persistence limitations.