Calculate the (Delta-)CoVaR of ticker conditional on conditioning_ticker being in its own distress state. Without a pair, it measures how much each ticker’s distress adds to the tail risk of the benchmark (the market as the “system”), as in Adrian & Brunnermeier (2016).

Ordinary Value at Risk treats each asset in isolation, which misses systemic risk – the fact that one asset’s distress can spill over and worsen another’s risk. CoVaR directly measures that spillover: it is the VaR of ticker, conditional on conditioning_ticker itself being at its own alpha-VaR, estimated via a linear Quantile Regression of ticker’s returns on conditioning_ticker’s returns at quantile alpha. The Delta-CoVaR isolates the marginal, distress-specific contribution by subtracting the same construction evaluated in the “normal” (median) state instead.

CoVaR was introduced to measure systemic risk: in its original application ticker is a financial-system index (or a bank’s peers) and conditioning_ticker a single institution, so the Delta-CoVaR reads as that institution’s contribution to system-wide tail risk. Because the quantile regression is fitted at the alpha quantile, it needs several years of daily data, and the result is a statement about co-movement in the tails, not about causality.

The formula is as follows (with the default alpha=0.05):

\[\operatorname{Quantile\_alpha}(A | B) = \text{Intercept} + \text{Slope} \cdot B\] \[\text{CoVaR} = \text{Intercept} + \text{Slope} \cdot \text{VaR}_{B}\] \[\text{Delta-CoVaR} = \text{Slope} \cdot (\text{VaR}_{B} - \operatorname{Median}(B))\]

Where A are the values of ticker and B those of conditioning_ticker on their common dates, the Intercept and Slope come from a linear quantile regression at quantile alpha (minimizing the check loss) and VaR_B is the empirical alpha-quantile of B.

For more information about the method, see the following paper:

  • Adrian, T., & Brunnermeier, M.K. (2016). “CoVaR.” American Economic Review, 106(7), 1705-1741.

Also known as: Conditional Value at Risk (systemic risk sense), Delta-CoVaR.

CoVaR in Python or via the MCP

Install the Finance Toolkit with:

pip install financetoolkit -U

Then call get_covar as shown below.

from financetoolkit import Toolkit

toolkit = Toolkit(
    ["GS", "JPM"],
    api_key="FINANCIAL_MODELING_PREP_KEY",
    start_date="2021-01-01",
    end_date="2025-12-31",
)

toolkit.risk.get_covar()[["CoVaR", "Delta-CoVaR"]]

Or, after setting up the Finance Toolkit MCP, ask:

What is the 95% CoVaR and Delta-CoVaR of the S&P 500 when Goldman Sachs or JPMorgan Chase is in distress, based on returns from 2021 to 2025?

Which returns:

  CoVaR Delta-CoVaR
GS -0.0232 -0.0104
JPM -0.0247 -0.012

Parameters

get_covar accepts the following parameters.

ParameterTypeDescriptionExample
tickerstr | NoneThe asset whose conditional VaR is being measured (the system). Defaults to None, which uses the benchmark."AAPL"
conditioning_tickerstr | NoneThe asset whose distress ticker is conditioned on. Defaults to None, which conditions ticker on every other ticker in the Toolkit instance in turn (the benchmark included when ticker is given), a row each."Benchmark"
periodstrThe data frequency (daily, weekly, monthly, quarterly, or yearly). Defaults to “daily”, since a dependence estimate needs far more observations than a lower frequency provides – at “yearly” a decade of history is only ten observations."weekly"
columnstrThe historical data column to use. Defaults to “Return”."Return"
alphafloatThe tail probability for both the tail quantile regression and the VaR of conditioning_ticker (e.g., 0.05 for the 95% confidence level). Defaults to 0.05.0.01
roundingint | NoneThe number of decimals to round the results to. Defaults to None.2
Share