I need to download the search volume from Google Trends for several words. Afterwards I'd like to save the files as csv.
I tried the following:
words <-c("Tennis","Fußball", "Handball") for ( i in 1:length(words) ){ trends <- gtrends(words[i], geo="DE",start_date = as.Date("2004-01-01"), end_date = as.Date(Sys.time()))$trend write.csv(trends, file="trends.csv") }
Obviously the data in trends gets overwritten, so that just the last word in this case Handball remains. How do I download several data?
Thank you for your help!
Ricarda