separated plotting and nont plotting scripts, fixed errors