OHDSI Home | Forums | Wiki | Github

Using conda to manage R version and package + python dependencies

Hi @schuemie, Thanks for your presentation. I wanted to suggest using conda as a package manager. It is much smaller than docker and you can specify the R version. It is also very stable. This should address some of the concerns you mentions about docker and renv.

After downloading miniconda or anaconda, code would be

conda create -n renv
conda activate renv
conda install -c conda-forge r-base=4.1.3

specific packages can be installed with the r- prefix

https://www.biostars.org/p/450316/
https://docs.anaconda.com/anaconda/user-guide/tasks/using-r-language/
https://docs.anaconda.com/anaconda/navigator/tutorials/create-r-environment/

Happy to create any specific sample env files to fit your use case

Best, Gene

1 Like
t