minor edits to mmode_sim.R file