TickRun definition: arithmetic mean daily strategy return divided by sample standard deviation of daily strategy returns, multiplied by √252. The current implementation subtracts no risk-free return.
The formula and what it asks
For periodic portfolio returns r and matching risk-free returns rf, the ex-post Sharpe ratio is commonly written:
Sharpe = mean(r − r_f) / standard_deviation(r − r_f)
The numerator is average excess reward per period. The denominator is the variability of that excess return. A positive ratio says average excess return was positive; a larger ratio says more average excess return was observed per unit of variability. It does not say how much money was earned, what the worst loss was, or whether the estimated relationship will persist.
William Sharpe originally called the concept a reward-to-variability ratio. His later clarification distinguishes an ex-ante ratio built from expectations from an ex-post ratio built from realized observations. A historical backtest computes the latter. Calling it “expected performance” silently turns an estimate into a forecast.
Exactly how TickRun calculates it
TickRun first forms net daily strategy returns. The position held from the preceding session earns the current close-to-close asset return, and any entry or exit cost is subtracted on the position-change row:
strategy_return[t] = position[t−1] × asset_return[t] − cost[t]
It then calculates the arithmetic mean of those daily returns, the sample standard deviation using n − 1 in the variance denominator, and:
TickRun Sharpe = daily_mean / daily_sample_std × √252
If volatility is zero, TickRun returns zero rather than infinity or an undefined value. The Buy & Hold benchmark is processed separately from its daily adjusted-close returns. Strategy costs are included; the benchmark currently has no modeled entry or exit charge.
Every flat day enters the strategy series with zero return. This is important. A market-timing rule that is invested for 30% of sessions is evaluated as a portfolio containing cash for the remaining 70%, not as a sequence containing invested days only. Removing flat days would answer a different question and usually distort annualization.
Why √252 appears—and when it fails
If daily returns are independent with constant variance, means scale approximately with the number of periods while standard deviations scale with the square root of time. Annualizing a daily ratio therefore multiplies it by √252, using 252 as a conventional number of trading sessions per year.
This shortcut is not an accounting identity. Serial correlation, volatility clustering, stale prices, overlapping holdings, and nonlinear payoffs weaken it. A strategy whose returns are positively autocorrelated can look smoother at daily frequency than its longer-horizon risk warrants. Calculating from weekly or monthly returns can produce a materially different annualized ratio even over the same history.
Frequency must be consistent throughout: daily mean with daily standard deviation and a daily risk-free rate; monthly quantities with √12. Multiplying a monthly ratio by √252 is not conservative—it is dimensionally wrong.
The zero risk-free assumption
The classical numerator is excess return. TickRun currently uses raw strategy return, equivalent to setting the daily risk-free rate to zero. That approximation is more consequential when interest rates are high, the strategy spends substantial time flat, or competing strategies have very different exposure.
A fully specified cash model would credit the uninvested fraction with an investable cash return, debit financing for leverage, and subtract the same-period risk-free return when constructing excess returns. TickRun is long-only and unlevered, but its zero-return cash assumption can still favor or penalize timing strategies depending on the period. Compare exposure before treating small Sharpe differences as meaningful.
Worked daily example
Suppose five net daily returns are 1.0%, −0.5%, 0%, 0.8%, and −0.2%. Their arithmetic mean is 0.22%. The sample standard deviation is approximately 0.64%. Under TickRun’s zero-risk-free convention, the annualized ratio is roughly 0.22 / 0.64 × √252 = 5.46.
That spectacular number is not credible evidence from five observations. Annualization changes units; it does not create information. The estimate has enormous sampling error and could be driven by a single day. This demonstrates why a precisely calculated statistic may still be poorly estimated.
What standard deviation assumes away
Standard deviation penalizes upside and downside deviations equally. A large positive surprise increases the denominator even though investors may welcome it. More importantly, two return series can have identical mean and standard deviation while having different skewness, tail losses, and drawdown paths.
Strategies that collect many small gains and occasionally suffer a severe loss can report attractive historical Sharpe ratios until the rare loss occurs. Options-like payoffs, stop-based rules, illiquid marks, and strategies with infrequent trading deserve particular caution. Review the equity curve, maximum drawdown, worst periods, trade distribution, and market regimes rather than treating normality as guaranteed.
A Sharpe estimate has uncertainty
The sample mean is noisy, and the ratio divides it by another estimated quantity. Short tests therefore produce unstable values. Searching thousands of configurations makes the maximum observed ratio even less reliable: the winner benefits from favorable sampling error as well as any real effect.
Do not interpret 1.12 versus 1.08 as a meaningful ranking without uncertainty analysis. Examine stability across subperiods, instruments, nearby parameters, cost assumptions, and untouched data. A confidence interval or resampling exercise should preserve time dependence rather than randomly shuffling individual daily returns when autocorrelation exists.
Rules for valid comparison
- Use the same return frequency and annualization convention.
- Use the same dates; market regime changes both mean and volatility.
- Use net portfolio returns, not raw trade returns.
- Apply a consistent risk-free and idle-cash model.
- Compare like leverage and exposure, or disclose the differences.
- Keep stale or missing observations from manufacturing artificial smoothness.
- Report the number of observations and alternatives tested.
- Pair Sharpe with drawdown, return, exposure, turnover, and trade evidence.
How to use it in TickRun
Use the displayed ratio as one description of the selected daily equity path. First confirm that the backtest contains enough sessions and completed trades. Compare strategy and benchmark over identical dates. Add plausible transaction costs, because reducing return on turnover rows changes both the numerator and the distribution. Inspect the equity curve for one-off gains or hidden tail events.
TickRun’s optimizer currently maximizes total return, not Sharpe. That avoids directly selecting the largest ratio, but the winning return configuration is still selected in sample and its displayed Sharpe inherits selection bias. Treat it as descriptive output for a candidate, then validate that frozen candidate chronologically.