I am trying to use Google Trends data and have come across a few packages that are not on CRAN (GTrends, RGoogleTrends).
I like what I have seen from the RGoogleTrends package at this blog, and wanted to give it a try. The RGoogleTrends package is located here: http://www.omegahat.org/RGoogleTrends/
First of all, I am using a Windows OS and there is an uption in my R console:
>Packages>Install package(s) from local zip drives ...
This results in the following:
> utils:::menuInstallLocal()
Error in read.dcf(file.path(pkgname, "DESCRIPTION"), c("Package", "Type")) :
cannot open the connection
In addition: Warning messages:
1: In unzip(zipname, exdir = dest) : error 1 in extracting from zip file
2: In read.dcf(file.path(pkgname, "DESCRIPTION"), c("Package", "Type")) :
cannot open compressed file 'RGoogleTrends_0.2-1.tar.gz/DESCRIPTION', probable reason 'No such file or directory'
I'm guessing this has to do with the fact that the file is as a .gz
and not a .zip
file.
So, I unzipped the .gz
file outside of R and then zipped it into a .zip
file (there's got to be a better way). Now I can install the .zip
file, but when I try and load it with library
, the following error occurs:
> library(RGoogleTrends)
Error in library(RGoogleTrends) :
‘RGoogleTrends’ is not a valid installed package
What am I doing wrong here?
R CMD INSTALL --build yourfile.tar.gz
. – Cist.gz
files outside of R, then I assume there should be a way to load the package without needing to install another program - correct? p.s. I have cygwin installed, but have never run R through it. – Schramminstall.packages(packageName, repos = "http://www.omegahat.org/R", type = "source")
as suggested at omegahat.org ? – Hardly