Libraries can be installed in the R conda environment the way we normally would (meaning no conda involved), but I occasionally have run into problems when doing things that way. So that’s why in the command above, I left solely the conda-forge channel as the only one specified. I then look at the number of downlaods from each, and typically have a preference for the conda-forge channel as I know that’s generally well-used and well-curated. To find the specific package names needed for conda, I’ll typically go to and do a search for the package I’m looking for.įor example, searching for “tidyverse” there brings up many hits of packages called “r-tidyverse” available from different channels. After that is installed, try running the rstudio command again.įinding a conda installation for a specific R library we want We can check which version of R are currently available to be installed through conda (using mamba here as also described on the conda intro page here) with the following:Īnd an installation window should pop up. Setting up a conda environment with R and RStudio If you aren’t yet already familiar with conda, I recommend running through the intro to conda page first, and having it installed as demonstrated there is required to follow below □ This page covers a little bit of how we can do that. Now, it’s generally easier, and easier for reproducibility, to create new environments with the wanted version of R and any needed packages, rather than installing a system-wide R and working in there hoping no conflicts arise. There was once a time when conda wasn’t really a viable way to manage R environments, but thanks to the work of many, that time has mostly completely passed. BONUS: Creating a conda environment with Jupyter Lab and an R kernel. Finding a conda installation for a specific R library we want.Opening RStudio in our conda environment.Setting up a conda environment with R and RStudio.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |