R scripts and associated notes for creating Schelling models in R