Unable to load an R package when installed from a custom directory

296 Views Asked by At

I already referred this post,post,

I am trying to install an R package called Aphrodite.

So, I downloaded the zip folder of R package from github and tried the below command

install.packages("C:/Users/test12/Downloads/Aphrodite.zip",repos=NULL,dependencies=TRUE,type="source")

The above command results in below message and moves the cursor to next line without any error message. Please note that all my packages goes into the below folder only.

Installing package into ‘C:/Users/test12/Documents/R/win-library/3.6’
(as ‘lib’ is unspecified)

However, when I try to use the below command, I get an error as shown below

library(Aphrodite)
Error in library(Aphrodite) : 
  ‘Aphrodite’ is not a valid installed package

I also tried the below option but it doesn't display some of the folders which are available in the master directory. The details of it can be referred in this post

install.packages("devtools")
library(devtools)
install_github("ohdsi/Aphrodite")  #APHRODITE is the package name
library(Aphrodite)

How can I load the package when it is installed from a custom directory? Why the package is not being recognized even though it is in the usual libpath folder?

0

There are 0 best solutions below