Fixed output and some errors for param-explore

Changed the *ans* definition so that it can compile. as well as setup
the output for csv.