Forked from StuartGordonReid/DrawdownAdjustedReturns.py
Created
January 5, 2021 00:47
-
-
Save wapebira/44b7e5bd76b7353631cb3bd95796d9a5 to your computer and use it in GitHub Desktop.
Risk adjusted returns based on Drawdown risk
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
Note that this Gist uses functions made available in another Gist - | |
https://gist.github.com/StuartGordonReid/67a1ec4fbc8a84c0e856 | |
""" | |
def calmar_ratio(er, returns, rf): | |
return (er - rf) / max_dd(returns) | |
def sterling_ration(er, returns, rf, periods): | |
return (er - rf) / average_dd(returns, periods) | |
def burke_ratio(er, returns, rf, periods): | |
return (er - rf) / math.sqrt(average_dd_squared(returns, periods)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment