Fixes to graphing scripts