Skip to content

Instantly share code, notes, and snippets.

@erichare
Last active July 20, 2022 13:25
Show Gist options
  • Save erichare/59217d2314871a8750f5fd7e7cfe02c2 to your computer and use it in GitHub Desktop.
Save erichare/59217d2314871a8750f5fd7e7cfe02c2 to your computer and use it in GitHub Desktop.
Extract Twitter Sentiment and store in Google Sheets with Daisi
import pydaisi as pyd
twitter_sentiment = pyd.Daisi("erichare/Twitter Sentiment")
google_spreadsheets = pyd.Daisi("erichare/Google Spreadsheets")
result = twitter_sentiment.get_twitter_sentiment("Pizza", count=10, tweets=None)
with open("service-account-file.json", "r") as my_f:
print(google_spreadsheets.store_in_gs(result, "[email protected]", my_f.read(), title="Pizza Dat", append = True).value)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment