Matana Labs

Optimization heatmaps: the “Two optimization maps” check

This check builds two optimization heatmaps for up to two numbers in your strategy: one on the fitting part of the period and one on the held-back part. The best cell is chosen on the fitting part only, then you see how it did on the part it never saw. A best cell that turns red on the held-back map, or that sits alone among weak neighbours, was fitted to the past.

What it checks

Best cell on the left and red on the right is a normal outcome — you should see it first.

The question behind it: Is it overfitted to history? In the app it is in Analysis Lab → Checks, stage “After optimization”. Were the numbers overfitted by brute force? Needed after parameter optimization in the “Improvement” step.

How it works

Up to two numbers from the strategy blocks (marked ones, otherwise the first two) — five values per axis: −40, −20, 0, +20, +40%. Each cell is an engine run on the head (70% of the period) and separately on the held-out tail (30%). The best cell is chosen by the head only; the tail wasn't seen during selection.

How it gets its status

These are the app’s own rules, shown on the check’s card:

With fewer than 30 trades or 20 days in the run, the check still shows its numbers, but its status is at most “with a caveat” and the result is marked as unreliable.

How to read the result

The Two optimization maps check in Matana Labs: two grids of results, one on the head for fitting and one on the held-back tail, with the best cell framed and the current values marked
“Two optimization maps” on a test data set: the same grid of values on the fitting head and on the held-back tail.

In the score out of 100

When it has a status, it counts toward the overall score with weight 1: “holds” earns full points, “with a caveat” half and “broke down” none; “can’t compute” is left out.

Every plan, the free one included, can run it; any engine runs it needs are counted in backtest-years.

If it breaks down

Optimization fits the past: fewer free numbers, a wider step, selection by the head only.

This is the app’s own suggestion; under Improvement the app tests candidate changes on the engine before it shows them.

Screenshots show the real app on a test data set. Backtests and simulations are not real trading, and past results don’t guarantee future ones. Not investment advice.

Keep reading

See Matana Labs plans, from free

Questions

Which numbers are used?

The numbers you marked for optimization, or else the first two numbers in the strategy’s blocks. Each gets a few values around the current one.

Why is a red best cell on the held-back map “normal”?

Because the best of many tries on one stretch of history often fails on the next. Seeing it first is the point of this check.

Do other checks use this grid?

Yes. The deflated Sharpe check and the Improvement step use the same optimization, computed once per run.