General Topics
Technical Topics
Brokerage Firms
Community Lounge
Site Support

# Sharpe Ratio - which formula to use for strat analysis?

Discussion in 'Programming' started by NetTecture, Jun 3, 2013.

1. ### NetTecture

According to

http://en.wikipedia.org/wiki/Sharpe_ratio

there is a component of benchmark (comparison) - which data to use for a backtest system? What do NinjaTrader or MultiCharts use there?

http://www.investopedia.com/terms/s/sharperatio.asp

also has expected portfolio return

Reason:

We have / build our own internal platform, and one of the guys got the glorius idea to include standard strat ratings there. Nice idea - I am nearly done with the NinjaTrader 7 strat sheet (that one with all the numbers in a grid in strategy analyzer).

The Sharpe Ratio, though, is a problem as I can not wrap my head around how to make it. I simply have no measure for the "risk free return". My best idea would be to put in some fake number (3% per year, based on the assumption that a conservative portfolio in retirement planning is assumed to carry a 4% withdrawal).

Or anyone has an idea how that is calculated in such programs?

3. ### cdcaveman

so in this package they use 0 as the default. i think you should leave it extensible with a default... so the user can pass it a value of what the risk free rate of return in his own view is for that time period..

4. ### NetTecture

Smells even worse than a sensible constant. But thanks for the link. I will provide both, a 0 rate and a 3% rate (still standing at 3% long term average making sense as long as they insist 4% is a good assumed payout from a retirement fund).

5. ### cdcaveman

i just would think over the life of your application these things might change.. this is why i mentioned letting the user specify the risk free rate of return.. as the whole idea of "risk free" is sort of left to ones own interpretation.. and even if you use a more typical treasury note.. those are always changing as well.. i don't know what language your using.. but more then likely you can use R programming along with it.. and the code is already written for some of these things..

6. ### kut2k2

Hi, NetTecture

What do you think of the following strategy performance metric? Thanks.

System Achievement Score

8. ### GeorgeClueney

Rather use Sortino Ratio instead of Sharpe or Sortino together with Sharpe. Sortino looks at downside deviation whereas Sharpe looks at both (upside deviation and downside deviation) equally.

9. ### slickpick

The answer is that it depends on your holding period. If you're making intraday trades, then just set it to 0. If you want to really picky about it, then just generate a yield curve using zero rates bootstrapped from H15.

Other metrics you probably want to consider for a backtesting system is max drawdown.

10. ### NetTecture

Thanks, I am aware of other key numbers - so far all had nice formulas that had no open questions. Max DD was easy to do.

Ah, now there is a good argument for a 0 reference rate - will do that

#10     Jun 6, 2013
ET IS FREE BECAUSE OF THE FINANCIAL SUPPORT FROM THESE COMPANIES: