adjusted to produce plots for the paper