【发布时间】:2019-03-22 12:05:25
【问题描述】:
你能帮帮我吗?
我有关于酒店的 CSV 数据集文件并包含许多列。我需要处理酒店名称和评论。
如何将酒店名称行转换为列?合并每个酒店的评论并将输出保存到新的 CSV 文件中?
我使用 Python 3.7
更新:首先感谢cmets
对不起,我必须假设输出的形状
我有超过 1400 家酒店
hotel-name reviews
Hotel Arena love it
Hotel Arena great
Hotel Arena good
Hotel Arena ........
the output will be :
hotel 1 hotel 2 hotel 3 .......
love it stay not bad
great old .....
good ... .......
..
...
....
【问题讨论】:
-
为您的问题提供输入、您的代码、您遇到的问题以及预期的输出。 Stack Overflow 不是获取免费代码的地方
标签: python file csv row multiple-columns