New graph scripts, bugfixes