Backtesting and statistical validation

Backtest any strategy.
Then find out if the edge is real.

AlphaGlyph runs quant and machine-learning strategies on real historical prices with simulated capital, then checks whether the result is skill or luck, using the tests quant funds use.

No account. No real money. Every trade explained in plain English.

Validation report: AlphaGlyph's own strategy grid Real result · SPY, 2026-08-01
Likely overfit
Overfitting risk 72% chance the in-sample winner lands in the bottom half out of sample
In-sample Sharpe 1.26 median: looks like a good strategy
Out-of-sample Sharpe 0.65 median: about half the edge survives
What AlphaGlyph found when it tested its own 42 strategy variants with combinatorial purged cross-validation. Picking the best backtest was worse than a coin flip. Your own backtests get three checks of their own: Monte Carlo, deflated Sharpe and Fama-French. Read the report
6strategies, plus a custom rule builder
1,000Monte Carlo paths per run
3independent validation tests
195automated tests in CI

Run a strategy. See the trades.
Get an honest verdict.

The whole flow lives on one page, the Backtester, with every step explained.

  1. 1

    Pick a strategy and run it

    Choose one of six strategies or build your own buy and sell rules. Pick stocks and dates, and it simulates day by day on real prices, with transaction costs.

  2. 2

    See every trade explained

    The equity curve against the S&P 500, each trade with a plain-English reason, and an optional animated replay of the whole run.

  3. 3

    Learn if it's real

    Three statistical tests combine into one verdict: significant, promising, or inconclusive.

Most backtests stop at a Sharpe ratio. This one asks if it's real.

Any strategy can look good on historical data by chance. AlphaGlyph runs three independent tests and combines them into a single verdict.

  • Resample reality

    1,000 bootstrap paths build a distribution. Your result either stands out or it doesn't.

  • Correct for luck

    The Deflated Sharpe Ratio penalises testing many strategies, the way good science corrects for multiple comparisons.

  • Isolate true skill

    Factor decomposition strips out market, size, and value exposure to show whether any genuine alpha remains.

stats.py
# Probability the Sharpe is real after
# testing N strategies on noisy data
def deflated_sharpe_ratio(returns, n_strategies):
    sr   = annualized_sharpe(returns)
    skew = scipy.stats.skew(returns)
    kurt = scipy.stats.kurtosis(returns)

    # expected max Sharpe from pure luck
    sr_star = expected_max_sharpe(n_strategies)

    return psr(sr, sr_star, skew, kurt)
    # → 0.964  significant

A quantitative toolkit, built from first principles.

Every indicator, model, and statistical method is implemented from scratch. No black-box TA libraries.

Six strategies and a rule builder

MA Crossover, RSI, MACD, a patient Dip Buyer, an ML transformer, and a no-code builder for your own buy and sell rules.

An ML transformer, evaluated honestly

Trained on a chronological 60/20/20 split, with backtests run strictly out of sample. The win is the rigour, not a magic edge.

Adaptive regime detection

ADX, Bollinger Band width, and realized volatility sort the market into four regimes, and the adaptive strategy switches to match.

Trailing stops and Kelly sizing

Wide trailing stops let winners run, and the Kelly criterion sizes positions by historical edge. No look-ahead, and it's tested.

Walk-forward and real costs

Grade only on a held-out final 30%, with commission and slippage charged on every buy and sell.

Leaderboard and optimizer

Rank every strategy on the same data, and compute the Markowitz efficient frontier in Tools.

Backtest a strategy now.

Run it on real history in seconds and see whether the edge holds up.