debtkit
Debt Sustainability Analysis and Fiscal Risk Assessment
Description
Analyses government debt sustainability using the standard debt dynamics framework from Blanchard (1990) <doi:10.1787/budget-v2-art12-en> and the IMF Debt Sustainability Analysis methodology (IMF, 2013) and the Sovereign Risk and Debt Sustainability Framework (IMF, 2022). Projects debt-to-GDP paths, decomposes historical debt changes into interest, growth, and primary balance contributions, and estimates fiscal reaction functions following Bohn (1998) <doi:10.1162/003355398555793>. Produces stochastic fan charts via Monte Carlo simulation, standardised stress tests, and IMF- style heat map risk assessments. Computes S1/S2 sustainability gap indicators used by the European Commission. All methods are pure computation with no external dependencies beyond base R; works with fiscal data from any source.
Downloads
407
Last 30 days
10626th
1.3K
Last 90 days
1.4K
Last year
Trend: -2.6% (30d vs prior 30d)
0
Last 30 days
25
Last 90 days
29
Last year
Trend: -100% (30d vs prior 30d)
4
Last 7 days
13
Last 30 days
0
All-time
autoCRAN-only: this name is served only by autoCRAN, so the count is exact.
CRAN Check Status
Show all 13 flavors
| Flavor | Status |
|---|---|
| r-devel-linux-x86_64-debian-clang | OK |
| r-devel-linux-x86_64-debian-gcc | OK |
| r-devel-linux-x86_64-fedora-clang | OK |
| r-devel-linux-x86_64-fedora-gcc | OK |
| r-devel-windows-x86_64 | OK |
| r-oldrel-macos-arm64 | OK |
| r-oldrel-macos-x86_64 | OK |
| r-oldrel-windows-x86_64 | OK |
| r-patched-linux-x86_64 | OK |
| r-release-linux-x86_64 | OK |
| r-release-macos-arm64 | OK |
| r-release-macos-x86_64 | OK |
| r-release-windows-x86_64 | OK |
Check History
OK 7 OK · 0 NOTE · 0 WARNING · 0 ERROR · 0 FAILURE Apr 1, 2026
Code
Structure
Lines of code
5,022
Files
49
Compiled share
0%
Has compiled src
No
Language breakdown
API
Exported functions
12
Internal functions
25
Recent export changes
Testing & CI
Has tests
Yes
Test-to-code ratio
0.51
testthat edition
3
CI present
No
CI type
[]
PR gated
No
Docs
Return-value doc rate
100%
\dontrun example ratio
0%
Roxygen coverage
100%
Has pkgdown
No
NEWS present
Yes
Health & Security signals
Informational signals; not verdicts.
on.exit coverage
100%
Unsafe pattern score
0
Dep constraint coverage
25%
Secret pattern count
0
Bundled 3rd-party code
2 items
Portability & License
Min R version
4.1.0
System requirements
–
C++ standard
–
License
MIT + file LICENSE
License flags
SPDX valid, OSI approved
History
Versions
1
First release
2026-03-31
Latest release
2026-03-31
Avg cadence
–
Cold removal rate
–
Dep drift
0
Per-file churn detail lives in the source pipeline: https://github.com/r-observatory/cran-code-metrics.