Merton Distance to Default
Calculate the distance to default and probability of default with the Merton (1974) structural credit model. Equity is seen as a call option on the company’s assets with its debt as strike price: shareholders receive what is left after the debt is repaid. The market value and volatility of the assets, which cannot be observed, are solved from the market value and volatility of the equity:
\[E = V N (d_{1}) - D e ^{- \text{rT}} N(d_{2})\] \[\sigma_{E} E = N(d_{1}) \sigma_{V} V\] \[\text{Distance to Default} = (\ln(V / D) + (r - \sigma_{V} ^{2} / 2) T) / (\sigma_{V} \;\text{sqrt} (T))\] \[\text{Probability of Default} = N(- \text{Distance to Default})\]where E is the market capitalization, σ_E the volatility of the share price over the year before, D the default point (short-term debt plus half of the long-term debt, the KMV convention), r the risk free rate and T the time horizon. The distance to default is the number of standard deviations the asset value is above the default point; it reacts to the share price immediately, long before a rating changes.
The risk free rate is the Toolkit’s (the 10-year Treasury yield unless set otherwise with risk_free_rate) at every period end, where Vassalou and Xing (2004) and Bharath and Shumway (2008) use the one-year rate for a one-year horizon; the difference moves the distance to default only slightly.
For more information, see the following papers:
- Merton, R.C. (1974). “On the Pricing of Corporate Debt: The Risk Structure of Interest Rates.” The Journal of Finance, 29(2), 449-470.
- Crosbie, P. and Bohn, J. (2003). “Modeling Default Risk.” Moody’s KMV.
- Vassalou, M. and Xing, Y. (2004). “Default Risk in Equity Returns.” The Journal of Finance, 59(2), 831-868.
- Bharath, S.T. and Shumway, T. (2008). “Forecasting Default with the Merton Distance to Default Model.” The Review of Financial Studies, 21(3), 1339-1369.
Also known as: KMV model, structural credit model, expected default frequency.
Merton Distance to Default in Python or via the MCP
Install the Finance Toolkit with:
pip install financetoolkit -U
Then call get_merton_distance_to_default as shown below.
from financetoolkit import Toolkit
toolkit = Toolkit(
["F", "AAPL"],
api_key="FINANCIAL_MODELING_PREP_KEY",
start_date="2021-01-01",
end_date="2025-12-31",
)
toolkit.models.get_merton_distance_to_default().loc["F"]
Or, after setting up the Finance Toolkit MCP, ask:
What were Ford's asset value, asset volatility, distance to default and probability of default in the Merton model in each year from 2021 to 2025?
Which returns:
| 2021 | 2022 | 2023 | 2024 | 2025 | |
|---|---|---|---|---|---|
| Equity Value | 8.37862e+10 | 4.66828e+10 | 4.92598e+10 | 3.98079e+10 | 5.22045e+10 |
| Equity Volatility | 0.4163 | 0.491 | 0.355 | 0.36 | 0.3319 |
| Default Point | 9.3892e+10 | 9.45665e+10 | 9.945e+10 | 1.07294e+11 | 1.1133e+11 |
| Asset Value | 1.76267e+11 | 1.3761e+11 | 1.44934e+11 | 1.42307e+11 | 1.58997e+11 |
| Asset Volatility | 0.1979 | 0.1675 | 0.1207 | 0.1008 | 0.109 |
| Distance to Default | 3.1592 | 2.3878 | 3.3814 | 3.2062 | 3.5969 |
| Probability of Default | 0.0008 | 0.0085 | 0.0004 | 0.0007 | 0.0002 |
Parameters
get_merton_distance_to_default accepts the following parameters.
| Parameter | Type | Description | Example |
|---|---|---|---|
time_horizon | float | The horizon in years over which default is measured. Defaults to 1. | 1 |
rounding | int | None | The number of decimals to round the results to. Defaults to None, which uses the Toolkit’s rounding. | 2 |
show_columns | list[str] | None | The periods to show. Defaults to None, all periods. | None, all periods |