Reformat a CSV file