Sovereign Debt Crisis
Get the Sovereign Debt Crisis dummy for a variety of countries over time from the Global Macro Database (GMDB). Unlike the other indicators in this module, this is a binary (0 = no crisis, 1 = crisis) Reinhart & Rogoff style crisis-dating series rather than a continuous economic series: a value of 1 marks a year in which a country was undergoing a sovereign debt crisis (e.g. a default or restructuring of government debt), and 0 marks a year in which it was not.
The crisis dating stops well short of the present – the series currently ends in 2017 – so recent years are NaN rather than 0.
Data comes from the Global Macro Database (GMDB), further information about the variable can be found within https://www.globalmacrodata.com/documentation.html
Also known as: sovereign default, debt crisis dummy.
Sovereign Debt Crisis in Python
Install the Finance Toolkit with:
pip install financetoolkit -U
Then call get_sovereign_debt_crisis as shown below.
from financetoolkit import Economics
economics = Economics(start_date='1980-01-01')
economics.get_sovereign_debt_crisis(countries='Argentina')
Which returns:
| Argentina | |
|---|---|
| 2016 | 0 |
| 2017 | 0 |
| 2018 | nan |
| 2019 | nan |
| 2020 | nan |
Parameters
The function accepts the following parameters:
- countries (list[str] | str | None, optional): A list of countries or a single country to include in the results. Defaults to None.
- rolling (int, optional): The rolling window size to use for smoothing the data (simple moving average). Defaults to None.
- trailing (int, optional): The trailing window size to use for summing the data over trailing periods (e.g. a trailing-4-quarter sum). Defaults to None.
- rounding (int | None, optional): The number of decimals to round the results to. Defaults to None.