I have a question about how to append data frame obtaining from the gtrendsR function.
My keywords are each "california" and "texas" and my geographic locations are each "US" and "FR". So, I have 4 trends (california and US, alifornia and FR, texas and US, and texas and FR).
Here is my code.
library(gtrendsR)
state <- c("california", "texas")
nation <- c("US", "FR")
for (i in state) {
for (j in nation){
g <- gtrends(keyword = i,geo = j,time ="2020-01-01 2020-01-05",gprop = "web")[[1]]
print(g)
}
}
So, I have 4 data frames with for loop. But, I could not append them into one data frame. Please help me solve this problem.
Thanks!