Moved pyplot import into graphing function, so script can be run on server.