Changed from write.csv to write table.