Added plotted graphics and code to create plots, also helper function to use the same code to read data in all the plotting codes