made some large improvements to the plotting