Skip to content
Snippets Groups Projects
Commit b29b9fff authored by Corentin Lasne's avatar Corentin Lasne
Browse files

modif du corps du code

parent a640491a
No related branches found
No related tags found
1 merge request!5modif du corps du code
import snscrape.modules.twitter as sntwitter
import pandas as pd
from src.functions import construct_query, convert_date_str, calc_frequency
from src.functions import construct_query, convert_date_str, calc_frequency, supress_n
table = pd.DataFrame(columns=['date', 'tweet'])
......@@ -20,7 +20,7 @@ for i, tweet in enumerate(sntwitter.TwitterSearchScraper(query=construct_query(t
break
if (tweet.lang in languages):
dict = {'date': convert_date_str(
tweet.date), 'tweet': tweet.rawContent}
tweet.date), 'tweet': supress_n(tweet.rawContent)}
if ("metaverse" in tweet.rawContent.lower()):
table = pd.concat([table, pd.DataFrame.from_records([dict])])
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment