user27612
user27612

Reputation: 55

Install local package from zip archive

How can I install a package from a zip file in R? I'm using the tools > install packages then selecting the install from 'Package Archive File (.zip, .tar.gz)' option. However an error message occurs. I have devtools installed, so the console window looks like this:

library("devtools", lib.loc="~/R/win-library/3.2")
install.packages("C:/Users/noodl/Downloads/RPUX/rpux_0.5.1/rpud_0.5.1.zip", repos = NULL)
Installing package into ‘C:/Users/noodl/Documents/R/win-library/3.2’ (as ‘lib’ is unspecified)

Error in install.packages : type == "both" cannot be used with 'repos = NULL'

I'm using R version 3.2

Upvotes: 0

Views: 3821

Answers (1)

r2evans
r2evans

Reputation: 160397

This is a common question ... so common, in fact, I didn't immediately find a SO question that was actually answered in an answer vice a comment. The most recent I found was @DirkEddelbuettel's comment here: add type="binary" to your command.

Upvotes: 2

Related Questions