Walk-Forward Analyzer
Score the results of a walk-forward test: walk-forward efficiency, how consistently the out-of-sample windows made money, and the stitched out-of-sample equity curve.
One row per walk-forward window: the net profit of the optimized in-sample (IS) period, and the net profit of the out-of-sample (OOS) period that followed it. Leave the day columns blank to use the default lengths below.
| Window | IS net profit ($) | IS days | OOS net profit ($) | OOS days |
|---|
CSV format
One row per walk-forward window, in time order. Most platforms (NinjaTrader, TradeStation, MultiCharts) list these figures in their walk-forward report.
| window | is_profit | is_days | oos_profit | oos_days |
|---|---|---|---|---|
| 1 | 18450 | 365 | 3120 | 90 |
| 2 | 21300 | 365 | 4480 | 90 |
| 3 | 16900 | 365 | -1250 | 90 |
| … | … | … | … | … |
is_profitandoos_profit(required): net profit of each in-sample and out-of-sample period.is_daysandoos_days(optional): calendar length of each period. If missing, the default lengths below are used.window(optional): a label such as a number or the OOS start date.
Default window lengths
How to Use the Walk-Forward Analyzer
Run a walk-forward test in your platform first, then copy each window’s in-sample and out-of-sample net profit into Enter windows, one row per window, or upload them as a CSV using the format shown. Add the length of each period in days, or leave those cells blank to use the default lengths. Click Analyze walk-forward. Walk-forward efficiency (WFE) compares the annualized out-of-sample profit rate with the annualized in-sample rate, so windows of different lengths are compared fairly. The results also show how many out-of-sample windows were profitable and whether one window carries the total.
Why Walk-Forward Analysis Matters for Strategy Validation
Optimized parameters always look good on the data they were fit to. Walk-forward analysis repeatedly optimizes on one period and then trades the next, unseen period, which is the closest a backtest gets to how you would actually run a strategy. A healthy result keeps a meaningful share of its in-sample performance and makes money in most out-of-sample windows; a sharp drop points to overfitting.
Go deeper: Walk-Forward Optimization guide · Out-of-Sample Testing guide · Walk-forward analysis in the trading glossary
Build Alpha generates thousands of strategy variations and can run walk-forward, Monte Carlo, noise and vs-random tests on each one automatically, so only strategies that hold up out-of-sample make your shortlist.
Generate and validate strategies in Build Alpha →Frequently Asked Questions
Walk-forward efficiency (WFE) is the annualized out-of-sample return divided by the annualized in-sample return. A WFE of 60% means the strategy kept 60% of its optimized performance on data it had not seen.
A commonly cited guideline, popularized by Robert Pardo, is a WFE of about 50% to 60% or higher. Below that, the optimization is probably fitting noise. Very high values (well above 100%) are uncommon and are often driven by one or two lucky windows.
In rolling walk-forward, the in-sample window keeps the same length and slides forward. In anchored walk-forward, the in-sample window always starts at the beginning of the data and grows. Both produce the same kind of in-sample and out-of-sample results, so either can be analyzed here.
A common starting point is an out-of-sample period of about 10% to 25% of the in-sample length, with enough trades in each in-sample window to optimize on. More windows give a more reliable picture than a few long ones.
In-sample and out-of-sample windows usually have different lengths. Comparing raw profit would make a one-year in-sample period look four times better than a three-month out-of-sample period even if performance were identical, so both are converted to a profit rate per year.
Related Tools
CFTC RULE 4.41: HYPOTHETICAL OR SIMULATED PERFORMANCE RESULTS HAVE CERTAIN LIMITATIONS. Unlike an actual performance record, simulated results do not represent actual trading. Also, since the trades have not been executed, the results may have under- or over-compensated for the impact, if any, of certain market factors, such as lack of liquidity. Simulated trading programs in general are also subject to the fact that they are designed with the benefit of hindsight. No representation is being made that any account will or is likely to achieve profit or losses similar to those shown.
Trading futures, forex, stocks and options involves substantial risk of loss and is not suitable for every investor. Past performance, whether actual or indicated by historical tests of strategies, is not indicative of future results. This tool is provided for educational purposes only and does not constitute investment advice or a recommendation to buy or sell any security or instrument. Calculations run entirely in your browser; your inputs and files are not uploaded or stored.