Package: contagionchannels 0.1.3

contagionchannels: Two-Stage Detection and Attribution of Cross-Border Financial Contagion Channels

Implementation of a two-stage framework for the joint detection-and-attribution of cross-border financial contagion. Stage one detects directional information flows between equity markets via Wavelet-Quantile Transfer Entropy, combining maximal-overlap discrete wavelet decomposition (Percival and Walden, 2000, ISBN:9780521685085) with the transfer-entropy estimator of Schreiber (2000) <doi:10.1103/PhysRevLett.85.461> and quantile conditioning following Han, Linton, Oka and Whang (2016) <doi:10.1016/j.jeconom.2016.03.001>. Stage two attributes each significant directional link to one of five mutually exclusive transmission channels (Trade, Financial, Geopolitical, Behavioural, Monetary Policy) through a multi-method structural identification architecture combining instrumental-variables two-stage least squares with channel-specific external instruments (Stock and Watson, 2018) <doi:10.1111/ecoj.12593>, LASSO-based instrument selection (Belloni, Chernozhukov and Hansen, 2014) <doi:10.1093/restud/rdt044>, local projections (Jorda, 2005) <doi:10.1257/0002828053828518>, heteroskedasticity-based identification (Rigobon, 2003) <doi:10.1162/003465303772815727>, and the Cinelli-Hazlett (2020) <doi:10.1111/rssb.12348> robustness-value sensitivity bound. Bundled datasets and replication scripts reproduce the headline findings of Bhandari, Parida and Sahu (2026) <doi:10.48550/arXiv.2604.26546>; the package is general-purpose and accommodates user-supplied returns and channel proxies.

Authors:Avishek Bhandari [aut, cre], Ipsita Parida [aut], Hitesh Kumar Sahu [aut]

contagionchannels_0.1.3.tar.gz
contagionchannels_0.1.3.zip(r-4.7-any)contagionchannels_0.1.3.zip(r-4.6-any)contagionchannels_0.1.3.zip(r-4.5-any)
contagionchannels_0.1.3.tgz(r-4.6-any)contagionchannels_0.1.3.tgz(r-4.5-any)
contagionchannels_0.1.3.tar.gz(r-4.7-any)contagionchannels_0.1.3.tar.gz(r-4.6-any)
contagionchannels_0.1.3.tgz(r-4.6-emscripten)
manual.pdf |manual.html
DESCRIPTION |NEWS
card.svg |card.png
contagionchannels/json (API)

# Install 'contagionchannels' in R:
install.packages('contagionchannels', repos = c('https://avishekb9.r-universe.dev', 'https://cloud.r-project.org'))

Bug tracker:https://github.com/avishekb9/contagionchannels/issues

Datasets:

On CRAN:

Conda:

4.71 score 17 scripts 471 downloads 22 exports 20 dependencies

Last updated from:1b8bd0d984. Checks:9 OK. Indexed: yes.

TargetResultTimeFilesSyslog
linux-devel-x86_64OK175
source / vignettesOK199
linux-release-x86_64OK176
macos-release-arm64OK139
macos-oldrel-arm64OK122
windows-develOK97
windows-releaseOK104
windows-oldrelOK107
wasm-releaseOK128

Exports:build_channel_compositesbuild_lagbuild_networkcinelli_hazlett_rvcompute_wqte_matrixiv_2sls_attributelasso_iv_attributeload_paper_datalocal_projectionsmodwt_detailnetwork_summaryorthogonalise_residualperiod_subsetplot_attribution_evolutionplot_attribution_stackplot_qte_intensityplot_robustness_valueqte_pairrigobon_idrun_contagion_pipelinewalktrap_communitieszscore

Dependencies:clicpp11glueigraphlatticelifecyclemagrittrMASSMatrixMatrixModelsmultitaperpkgconfigquantregrlangSparseMsurvivalvctrswaveslimxtszoo

Methodology Guide
Overview | 1. The detection-attribution distinction | 2. Stage 1: WQTE math intuition | Transfer entropy | Wavelet decomposition | Quantile conditioning | Bias correction | 3. Stage 2: why multi-method identification? | 4. IV/2SLS with channel-specific instruments | 5. LASSO instrument selection | 6. Local projections | 7. Rigobon heteroskedasticity-based identification | 8. Cinelli-Hazlett robustness value | 9. Identification-status classification | Session info

Last update: 2026-04-29
Started: 2026-04-29

Replicating the Paper Results
Overview | 1. Setup | 2. Loading the bundled datasets | 3. Building the v2 channel composites | 4. Stage 1: WQTE detection | Absolute thresholding | 5. Stage 1 results: density and centrality (Table 1) | 6. Stage 2: IV/2SLS attribution (Table 2) | 7. Cross-method comparison: LP and Rigobon (Table 6) | Sargan over-identification | 8. Bootstrap confidence intervals | 9. Cinelli-Hazlett robustness values | 10. Visualisation walkthrough (Figures 1-7) | 11. Walktrap communities | 12. End-to-end pipeline | Session info

Last update: 2026-04-29
Started: 2026-04-29

Using Custom Datasets
Overview | 1. Required data structure | 2. Custom market list and crisis periods | 3. Custom channel composites | 4. Calling the pipeline | 5. Adapting visualisations for custom data | 6. Worked example: synthetic five-market panel | Common pitfalls | Session info

Last update: 2026-04-29
Started: 2026-04-29