Export to CSV file.
closes #5. closes #6.