Skip to main content

8. Backtests module

Module link: https://my.whalepro.org/backtests/

8.1. Purpose

The “Backtests” module is designed to test previously created Alerts over a historical interval for a trading pair.

Attention: if you do not have alerts created, this module will not work!

When creating a backtest you can select up to two Alerts and a history interval of up to 7 years.

If two alerts are selected, they are checked separately: the system first finds points where all conditions for the first alert are met, then for the second alert. So we get separate points for each alert.

Note: currently access to backtests is available only on the Professional plan.

8.2. Overview

1 — Start buttons for running a backtest.

Backtests with 1 or 2 alerts are supported.

2 — List of completed backtests with controls.

Controls:

3 — “Edit backtest” icon

Opens the backtest edit form. Important: saving deletes previous results because the system treats the edited backtest as “new”.

4 — “Copy backtest” icon

Opens the create backtest form using the existing one as a template.

5 — “Delete backtest” icon

6 — “View backtest settings” icon

7 — “Open backtest results chart” icon

8.3. Adding a backtest

Let’s create a backtest for a single alert.

Click “New backtest 1 alert”.

The backtest settings menu opens

1 — Name

2 — Period

3 — Start, End dates

Alert section

4 — Alert selection

5 — Position size

6 — Entry lag

7 — Leverage

8 — “Entry filters” section

9 — Position change on repeated alert trigger

Backtest configuration parameters

Name — any name for easier identification in the list.

Period — the time interval to test over. Choose from presets (1m, 3m, 6m, 1y, etc.) or set custom start/end dates.

Alert selection — choose a pre-created alert to test on historical data. Alerts are created in the “Chart” module.

Position size — the amount used to open a position when the alert triggers.

Entry lag — delay between alert trigger and position open, modeling real-world conditions.

Leverage — leverage size used when opening positions in the backtest.

Entry filters — extra conditions that must be met to open a position in addition to the main alert.

Position change on repeated alert — behavior when the alert triggers again while a position is open: ignore, increase position, close and reopen.

8.4. Viewing results

After starting a backtest, the system analyzes historical data and finds all points where the alert conditions are met. For each such point, a position is modeled according to parameters and subsequent price changes are tracked.

Results are presented as:

  1. Chart with entry/exit points
  2. Table with per-trade statistics
  3. Summary performance metrics

Key metrics to analyze:

  • Total profit/loss
  • Win rate
  • Average profit per trade
  • Maximum drawdown
  • Risk/reward ratio

To view results click the “Open backtest results chart” icon in the list.

8.5. Example

Example: create and analyze a backtest for an alert tracking buy volume spikes on BTCUSDT.

  1. Create an alert in the “Chart” module that triggers when buy volume exceeds a threshold.
  2. In “Backtests” click “New backtest 1 alert”.
  3. Name it “BTC volume test”.
  4. Select the last year as the test period.
  5. In the “Alert” section select your buy-volume alert.
  6. Set position size to 1000 USDT.
  7. Set entry lag to 1 hour.
  8. Set leverage to 1x.
  9. In “Entry filters” add a condition that 24h change is between -2% and +2%.
  10. Click “Save and run”.

After completion analyze results:

  • Check overall strategy return
  • Analyze distribution of winners/losers
  • Study periods of best performance
  • Adjust alert parameters or entry conditions based on findings
  • Run a new backtest and compare

This iterative process helps optimize a trading strategy before applying it to a real account.