script to generate CSV results