Update the creation of averaged data to make the graphs