opensafely-core / r-docker

Docker image for running R scripts in OpenSAFELY
1 stars 3 forks source link

request for adding packages, please #115

Closed rriefu closed 2 years ago

rriefu commented 2 years ago

Hi, I was wondering if these two packages could be added :

  1. https://cran.microsoft.com/snapshot/2022-02-03/web/packages/randomForest/ (updated)
  2. https://cran.r-project.org/web/packages/randomForestExplainer/index.html

These two packages are about random forest and we need them in our analyses. Thank you.

remlapmot commented 2 years ago

(this is not from the team)

The randomForest CRAN page shows that its current version requires R >= 4.1.0, and hence that won't install in the current container (which has R 4.0.2).

Screenshot 2022-11-02 at 11 18 05

The previous version of randomForest also had that requirement, but 2 versions back (4.6-14) didn't https://cran.microsoft.com/snapshot/2022-02-03/web/packages/randomForest/

Screenshot 2022-11-02 at 11 26 54

So I recommend using

install.packages("randomForest", repos = "https://cran.microsoft.com/snapshot/2022-02-03")

to install 4.6-14.

The current version of randomForestExplainer will probably install (it requires randomForest >= 4.6-12).

rriefu commented 2 years ago

@remlapmot thanks for checking. I've updated the link you provided.

wjchulme commented 2 years ago

If issues Tom mentioned can be resolved then these are ok to be added @opensafely-core/pipeline-team

rebkwok commented 2 years ago

These packages (with the suggested versions) have been installed now.