简体   繁体   中英

Tweet collection using Python Tweepy

I am collecting Data from twitter for data analysis using python tweepy. code is: Python tweepy 代码

Data is saved in json format.But i need to convert it in .csv format. Data sample is: 数据样本

But it is showing error that json is invalid. Can you tell me how can i convert this data in .csv format.

JSON data must be a single object, whereas you have an object every line. It's better to store it as an array of objects as that is considered valid JSON.

eg

[{"created_at"...},
{"created_at"...},
{"created_at"...}]

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM