Updating plotting codes