Hi all,
I have a question relating to the output of R when downloading Google trends data.
I want to download Google trends data for the past 7 days.
My code is:
sink("output1.txt ")
print(head(gtrends(c("VCB"), geo = "VN", time = "now 7-d", gprop = c("web"), category = 7, hl = "en-US", low_search_volume = TRUE) $interest_over_time))
sink()
And the output is:
date hits keyword geo gprop category
1 2018-05-01 16:00:00 41 VCB VN web 7
2 2018-05-01 17:00:00 73 VCB VN web 7
3 2018-05-01 18:00:00 81 VCB VN web 7
4 2018-05-01 19:00:00 72 VCB VN web 7
5 2018-05-01 20:00:00 60 VCB VN web 7
6 2018-05-01 21:00:00 44 VCB VN web 7
My question is: Why there is only 6 observations in the output?
And I also get this:
Warning messages:
1: In as.POSIXlt.POSIXct(x, tz) : unknown timezone 'Asia/Taipei'
2: In as.POSIXlt.POSIXct(x, tz) : unknown timezone 'GMT'
3: In as.POSIXlt.POSIXct(x, tz) : unknown timezone 'America/New_York'
4: In as.POSIXlt.POSIXct(x, tz) : unknown timezone 'Asia/Taipei'
5: In as.POSIXlt.POSIXct(x, tz) : unknown timezone 'GMT'
6: In as.POSIXlt.POSIXct(x, tz) : unknown timezone 'America/New_York'
I guess I need to specify time zone, even if I already set geo=VN?
Thank you.