Skip to content
This repository has been archived by the owner on Jul 8, 2024. It is now read-only.

How can I export results to a csv file? #90

Open
dipsola opened this issue Jul 26, 2020 · 1 comment
Open

How can I export results to a csv file? #90

dipsola opened this issue Jul 26, 2020 · 1 comment

Comments

@dipsola
Copy link

dipsola commented Jul 26, 2020

No description provided.

@cefasgarciapereira
Copy link

import GetOldTweets3 as got
import pandas as pd

tweetCriteria = got.manager.TweetCriteria().setUsername("barackobama whitehouse")\
                                           .setMaxTweets(10)
tweets = got.manager.TweetManager.getTweets(tweetCriteria)
df = pd.DataFrame(t.__dict__ for t in tweets)
df.to_csv('tweets.csv')

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants