Conte-Ecology / conteStreamTemperature

Package for cleaning and analyzing stream daily stream temperature
MIT License
1 stars 1 forks source link

Package installation woes #9

Closed Tom-Bombadil closed 10 years ago

Tom-Bombadil commented 10 years ago

So I am having some issues installing everything to run the package.

1) Rtools

I have downloaded and installed Rtools (3.1) and devtools (1.5) as directed. When I load devtools I get a warning about rtools not being installed:

library(devtools) WARNING: Rtools is required to build R packages, but is not currently installed.

Please download and install Rtools 3.1 from http://cran.r-project.org/bin/windows/Rtools/ and then run >find_rtools().

Attaching package: ‘devtools’

The following objects are masked from ‘package:utils’:

?, help

The following object is masked from ‘package:base’:

system.file`

When I run find_rtools() is does not find rtools. I've tried this for a couple of different locations of rtools. When I run debug:

find_rtools(TRUE) Scanning path... ls : C:\ArcGIS\gbin\ls.exe gcc: C:\STRAWB~1\c\bin\gcc.exe Scanning registry...

WARNING: Rtools is required to build R packages, but is not currently installed.

Please download and install Rtools 3.1 from http://cran.r-project.org/bin/windows/Rtools/ and then run find_rtools()

So clearly it seems to be looking in the wrong place (the first directory in C:). Anyone know of a way to edit the path? I tried setting the directory, but no luck.

2) rmarkdown

This error may be because of the previous one, or it may be independent. When I first tried to install conteStreamTemperature package it stated that R version 3.1 was required. Now, after downloading version 3.1, I am getting an error saying that one of the dependencies (rmarkdown) is not available for R 3.1.

install_github("conteStreamTemperature", username = "Conte-Ecology") Installing github repo conteStreamTemperature/master from Conte-Ecology Downloading master.zip from https://github.com/Conte-Ecology/conteStreamTemperature/archive/master.zip Installing package from C:\Users\koneil\AppData\Local\Temp\1\RtmpclaVDQ/master.zip Installing conteStreamTemperature Installing dependencies for conteStreamTemperature: rmarkdown Installing package into ‘C:/Users/koneil/Documents/R/win-library/3.1’ (as ‘lib’ is unspecified) "C:/PROGRA~1/R/R-31~1.1/bin/x64/R" --vanilla CMD INSTALL "C:\Users\koneil\AppData\Local\Temp\1\RtmpclaVDQ\devtools198453fc3018\conteStreamTemperature-master" \ --library="C:/Users/koneil/Documents/R/win-library/3.1" --install-tests

ERROR: dependency 'rmarkdown' is not available for package 'conteStreamTemperature' *removing 'C:/Users/koneil/Documents/R/win-library/3.1/conteStreamTemperature' Error: Command failed (1) In addition: Warning message: package ‘rmarkdown’ is not available (for R version 3.1.1)

I'll keep looking around and see if I can make sense of what's going on, but I also wanted to put this out there in case someone has experienced it before and knows how to fix it. For now I'll make changes to the code and test the old fashioned way, although I'm not able to check anything package format-wise.

djhocking commented 10 years ago

I'm not sure about RTools on Windows. I can try later today or tomorrow on the Windows machine here at UNH if Jeff doesn't have a quick answer. I think I may have built it from source on my Mac. I can't remember the details, but they'd likely be different.

I should add specific versions to the dependencies in the package. On the todo list. I am running R version 3.1.0 rather than 3.1.1, so that may be the difference for rmarkdown. I suspect that you can get it from GitHub or CRAN source for 3.1.1 but I don't know for sure off-hand.

walkerjeffd commented 10 years ago

it could be that rtools wasn't added to your environmental variable PATH. see this

if you haven't used PATH before, you can find it by going to Control Panel > System and Security > System > Advanced System Settings > Advanced tab > Environment Variables. Then under System variables, go to Path. You should have "c:\Rtools\bin;C:\Rtools\gcc-4.6" in there, should be at the beginning (assuming you installed RTools to C:\Rtools, if you manually changed the folder that might be the reason). if they're not there, then add them in, reboot, and try again.

actually, if you just installed rtools, you may just have to reboot so i'd try that first. if it still doesnt work, check the path.

Tom-Bombadil commented 10 years ago

Thanks for the suggestions. I won't be on that machine until after the weekend so I'll give them a shot on Tuesday morning and report back on what works.

Tom-Bombadil commented 10 years ago

Alright, everything looks to be running smoothly. My issue with Rtools was not checking the box that specified the path. Manually changing it didn't help so I just re-installed it which works. I downloaded rmarkdown from GitHub which is also working.

Thanks for the help guys.