old scripts for plotting