statgen / Rprs

R package for computing Polygenic Risk Scores (PRS)
GNU General Public License v3.0
10 stars 3 forks source link

how to install? #14

Open complexgenome opened 4 years ago

complexgenome commented 4 years ago

1) download

git clone "https://github.com/statgen/Rprs.git"

2) Go to the library you'd like to install

R CMD INSTALL ../Rprs -l ./ Warnings and errors:


Downloading https://github.com/statgen/savvy/archive/5cf11170e5d.tar.gz
Download failed with error 400 for: //github.com/statgen/savvy/archive/5cf11170e5d.tar.gz
Failed to build package statgen/savvy
ERROR: configuration failed for package ‘Rprs’

If I don't clone in a seprate directory upon tryial to install it errors out. Two steps:

git clone "https://github.com/statgen/Rprs.git"

R CMD INSTALL Rprs -l ./

Error

ERROR: cannot install to srcdir for package ‘Rprs’
 removing ‘/mnt/mfs/hgrcgrid/path/libraries_R/R_LIB4.0/Rprs’

Any clues? I'm on debian, R4.0

jonathonl commented 4 years ago

Are you behind a proxy? If so, see https://github.com/pfultz2/cget/issues/77.

complexgenome commented 4 years ago

Yes, I'm behind proxy and http, https are already set to circumvent proxy firewalls.

Which one of the above two methods is good for installation?

jonathonl commented 4 years ago

I'm not sure which "two methods" you are referring to. In any case, is the http_proxy environment variable set when when you run the install? See https://stackoverflow.com/questions/3168171/how-can-i-open-a-website-with-urllib-via-proxy-in-python. This package uses a python script that uses urllib to install dependencies. These dependency downloads are failing due to a quirk with urllib and HTTP proxies.

complexgenome commented 4 years ago

I've following two lines in my .bashrc file

export http_proxy="some value"
export https_proxy="some more value"

I'm referring to the following two methods, sorry I wasn't clear in my first post:

method 1

git clone "https://github.com/statgen/Rprs.git"

R CMD INSTALL Rprs -l ./

method 2: a two step process

a) download git clone "https://github.com/statgen/Rprs.git"

b) Go to the library you'd like to install cd r_lib_folder R CMD INSTALL ../Rprs -l ./

folder ../Rprs is one level above the r_lib_folder directory.

best,