STARR Ratio
Calculate the STARR (Stable Tail Adjusted Return Ratio) of an investment portfolio or asset’s returns.
The Sharpe ratio penalizes upside and downside volatility equally via the standard deviation. The STARR ratio instead scales the mean excess return by the Conditional Value at Risk (CVaR / Expected Shortfall), a coherent tail-risk measure that only looks at the average magnitude of losses beyond the alpha quantile. This makes STARR more appropriate than the Sharpe ratio for return distributions with fat left tails.
The formula is as follows:
\[\text{STARR Ratio} = \text{Excess Return} / | \operatorname{CVaR}(\alpha) |\]See definition: https://en.wikipedia.org/wiki/Expected_shortfall
Also known as: Stable Tail Adjusted Return Ratio, Conditional Sharpe Ratio.
No programming experience? With the Finance Toolkit MCP server, AI assistants such as Claude and ChatGPT can calculate the STARR Ratio for you. Just ask in plain English.
Calculate the STARR Ratio in Python
The STARR Ratio is available in the Performance module of the open-source Finance Toolkit. Install it with:
pip install financetoolkit -U
Then call get_starr_ratio as shown below.
from financetoolkit import Toolkit
toolkit = Toolkit(["AAPL", "TSLA"], api_key="FINANCIAL_MODELING_PREP_KEY")
toolkit.performance.get_starr_ratio()
Which returns:
| Date | AAPL | TSLA |
|---|---|---|
| 2022 | -0.4203 | -0.4759 |
| 2023 | 1.0763 | 0.8716 |
| 2024 | 0.5566 | 0.4707 |
| 2025 | 0.0677 | 0.0554 |
| 2026 | 0.1743 | -0.3805 |
Parameters
get_starr_ratio accepts the following parameters:
- period (str, optional): The period to use for the calculation. Defaults to “quarterly” if the Toolkit is initialised with quarterly=True, otherwise “yearly”.
- within_period (bool, optional): Whether to calculate the CVaR within the specified period or for the entire period. Thus whether to look at the CVaR within a specific year (if period = ‘yearly’) or look at the entirety of all years. Defaults to True.
- alpha (float, optional): The confidence level used for the CVaR calculation (e.g. 0.05 for the worst 5% of outcomes). Defaults to 0.05.
- rounding (int, optional): The number of decimals to round the results to. Defaults to 4.
- growth (bool, optional): Whether to calculate the growth of the ratios. Defaults to False.
- lag (int | str, optional): The lag to use for the growth calculation. Defaults to 1.
- standardize (bool, optional): Whether to standardize (Z-Score) the result. When combined with growth=True, standardizes the growth values instead of the raw values. Defaults to False.
Related Performance Metrics
The Performance module page introduces the module, and the sidebar lists all of its functions.