Write as correct csv format