File Exchange

image thumbnail

Exploring Risk Contagion Using Graph Theory and Markov Chains (Live Editor Version)

version (2.66 MB) by Ken Deeley
Describe, visualize and model sector risk contagion for a portfolio of securities


Updated 01 Sep 2016

View Version History

View License

This submission contains the MATLAB live script for the technical article "Exploring Risk Contagion Using Graph Theory and Markov Chains".
The live script contains all the code, output, equations, and images in the article. You can download the script, open it in MATLAB, and explore the steps in the analysis described in the article.
R2016a or above is required to use the MATLAB Live Editor. If you don’t have R2016a, you can
download a free trial.
Learn more about the MATLAB Live Editor.

Cite As

Ken Deeley (2021). Exploring Risk Contagion Using Graph Theory and Markov Chains (Live Editor Version) (, MATLAB Central File Exchange. Retrieved .

Comments and Ratings (3)

Ken Deeley

Hi Davide,

Many thanks for bringing this issue to my attention. Please open a parallel pool before running the main RiskContagion script:

>> parpool

It seems that if a pool is already running, then we don't encounter this issue. I will investigate the root cause of this error.

Many thanks,


No way. I have R2020b and still get the same issue

Error using tabular/numArgumentsFromSubscript (line 78)
Unrecognized table variable name 'internal'.

code is buggy

Caxap Puc

MATLAB Release Compatibility
Created with R2016a
Compatible with any release
Platform Compatibility
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!