[问题类型]:
程式咨询(我想用R 做某件事情,但是我不知道要怎么用R 写出来)
[软件熟悉度]:
请把以下不需要的部份删除
新手(没写过程式,R 是我的第一次)
[问题叙述]:
使用gtrendsR套件,出现下列错误讯息,但不知道该如何解决。
错误: Not enough search volume. Please change your search terms.
此外: Warning message:
In request_GET(x, url, ...) : Gone (HTTP 410).
[程式范例]
install.packages("gtrendsR")
library(gtrendsR)
account_code <- gconnect(usr = "username", psw = "password")
gtrends(query = "Brexit",start_date = "2016-01-01",end_date = "2017-07-15")[程式范例]:
usr与psw是登入gmail的帐号密码,不方便给大家,跟大家说抱歉。
[环境叙述]:
> sessionInfo()
R version 3.3.2 (2016-10-31)
Platform: x86_64-apple-darwin13.4.0 (64-bit)
Running under: macOS Sierra 10.12.3
locale:
[1] zh_TW.UTF-8/zh_TW.UTF-8/zh_TW.UTF-8/C/zh_TW.UTF-8/zh_TW.UTF-8
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] gtrendsR_1.3.5
loaded via a namespace (and not attached):
[1] Rcpp_0.12.10 lattice_0.20-35 codetools_0.2-15 XML_3.98-1.6
[5] zoo_1.8-0 grid_3.3.2 plyr_1.8.4 R6_2.2.0
[9] jsonlite_1.4 gtable_0.2.0 magrittr_1.5 scales_0.4.1
[13] ggplot2_2.2.1 httr_1.2.1 stringi_1.1.5 curl_2.6
[17] lazyeval_0.2.0 googleVis_0.6.2 xml2_1.1.1 tools_3.3.2
[21] stringr_1.2.0 selectr_0.3-1 munsell_0.4.3 colorspace_1.3-2
[25] rvest_0.3.2 tibble_1.3.0
[关键字]:
gtrendsR