Added ability to save as CSV.