OPEN-SOURCE SCRIPT

Sortino Ratio

The Sortino ratio is a variation of the Sharpe ratio that differentiates harmful volatility from total overall volatility using the asset's standard deviation of negative portfolio returns—downside deviation—instead of the total standard deviation of portfolio returns. The Sortino ratio takes an asset or portfolio's return and subtracts the risk-free rate and then divides that amount by the asset's downside deviation. The ratio was named after Frank A. Sortino.

What Can the Sortino Ratio Tell You?

The Sortino ratio is useful for investors, analysts, and portfolio managers to evaluate an investment's return for a given level of bad risk. Since this ratio uses only the downside deviation as its risk measure, it addresses the problem of using total risk, or standard deviation, which is important because upside volatility is beneficial to investors and isn't a factor most investors worry about.

The Difference Between the Sortino Ratio and the Sharpe Ratio

The Sortino ratio improves upon the Sharpe ratio by isolating downside or negative volatility from total volatility by dividing excess return by the downside deviation instead of the total standard deviation of a portfolio or asset.

The Sharpe ratio punishes the investment for good risk, which provides positive returns for investors. However, determining which ratio to use depends on whether the investor wants to focus on total or standard deviation or just downside deviation.

CONCLUSION: THE HIGHER THE RATIO, THE BETTER IT IS.

Note: The default risk-free rate is based on the Malaysian rate. Please change based on your country rate.
Note: The default length is based on 1 year Malaysia trading day (11/6/2020 - 11/6/2021).
Note: Sortino ratio is good for assessing a long-term investment, and thus, please use a longer time frame to get a better risk assessment.

Please let me know if this script contains any mistake. Cheers!
Volatility

開源腳本

在真正的TradingView精神中,這個腳本的作者以開源的方式發佈,這樣交易員可以理解和驗證它。請向作者致敬!您可以免費使用它,但在出版物中再次使用這段程式碼將受到網站規則的約束。 您可以收藏它以在圖表上使用。

想在圖表上使用此腳本?

免責聲明