Learn R Programming

systemicrisk (version 0.4.2)

A Toolbox for Systemic Risk

Description

A toolbox for systemic risk based on liabilities matrices. Contains a Gibbs sampler for liabilities matrices where only row and column sums of the liabilities matrix as well as some other fixed entries are observed. Includes models for power law distribution on the degree distribution.

Copy Link

Version

Install

install.packages('systemicrisk')

Monthly Downloads

451

Version

0.4.2

License

GPL-3

Maintainer

Axel Gandy

Last Published

January 13th, 2019

Functions in systemicrisk (0.4.2)

calibrate_FitnessEmp

Calibrate empirical fitness model to a given density
Model.p.Betaprior_mult

Model Using Multiple Independent Components
Model.p.Fitness.Servedio

Multiplicative Fitness Model for Power Law
sample_ERE

Sample from the ERE model with given row and column sums
getfeasibleMatr

Creates a feasible starting matrix
default

Default of Banks
choosethin

Calibrate Thinning
cloneMatrix

Creates a deep copy of a matrix
Model.lambda.constant.nonsquare

Model for a Constant lambda and Non-Square Matrices
Model.p.BetaPrior

Model for a Random One-dimensional p
Model.p.constant

Model for a Constant p
Model.p.constant.nonsquare

Model for a constant p and Non-Square Matrices
diagnose

Outputs Effective Sample Size Diagonis for MCMC run
findFeasibleMatrix_targetmean

Creates a feasible starting matrix with a desired mean average degree
genL

Generate Liabilities Matrix from Prior
Model.fitness.genlambdaparprior

Prior distribution for eta and zeta in the fitness model
findFeasibleMatrix

Finds a Nonnegative Matrix Satisfying Row and Column Sums
calibrate_ER

Calibrate ER model to a given density
calibrate_ER.nonsquare

Calibrate ER model to a given density with a nonsquare matrix
default_cascade

Default Cascade
default_clearing

Clearing Vector with Bankruptcy Costs
sample_HierarchicalModel

Sample from Hierarchical Model with given Row and Column Sums
steps_ERE

Perform Steps of the Gibbs Sampler of the ERE model
Model.fitness.meandegree

Mean out-degree of a random node the fitness model
Model.lambda.GammaPrior

Model with Gamma Prior on Lambda
Model.fitness.conditionalmeandegree

Mean out-degree of a node with given fitness in the fitness model
Model.Indep.p.lambda

Combination of Independent Models for p and lambda
ERE_step_cycle

Does one Gibbs Step on a cycle
Model.additivelink.exponential.fitness

Fitness model for liabilities matrix
Model.lambda.Gammaprior_mult

Model Using Multiple Independent Components
Model.lambda.constant

Model for a Constant lambda
GibbsSteps_kcycle

Gibbs sampling step of a matrix in the ERE model