updated scripts to match @zwelchWI's work