This is script is used to simulate Self Organized Criticality (SOC) in a Global Contact Process (GCP) model of excitability, as described in Gal and Marom 2013. The version that appears here simulate the model under 48 hours of constant stimulation at 5Hz, and plots the histogram of inter spike intervals. It can be easily modified to recreate the other figures that appear in the paper.
Journal of Neurophysiology (2003)
Davison Andrew P., Feng Jianfeng, and Brown David