-1

I stumbled on this post:

Install of R in miniconda

https://community.rstudio.com/t/install-of-r-in-miniconda/19755

Is it possible to install R in miniconda? As I understand it miniconda is a package manager for Python only according to this definition:

Miniconda

Miniconda is a free minimal installer for conda. It is a small, bootstrap version of Anaconda that includes only conda, Python, the packages they depend on, and a small number of other useful packages, including pip, zlib and a few others. Use the conda install command to install 720+ additional conda packages from the Anaconda repository.

https://docs.conda.io/en/latest/miniconda.html

Or is it possible to use it with R?

I know Anaconda 3 offers R support.

Thanks.

Ormetrom2354
  • 315
  • 3
  • 11
  • Have you read the posts in the link you provided? It describes a direct methodology and suggested fix in case it doesnt work. – Oliver Dec 19 '21 at 11:24
  • Can you be more specific? – Ormetrom2354 Dec 19 '21 at 11:28
  • Try reading the comments to the link you provided in your question, within there they describe how to solve the problem. – Oliver Dec 19 '21 at 12:41
  • Again you are not specific. If you refering to the link to the doc, this does not answer my question. I knew I could install R in Anaconda full version like explained there. I did not know I could install R with Miniconda. The right answer Miniconda is the command line tool for Conda and not only a package manager for Python. R can than be installed with Miniconda. The definition of conda given here was irritating me: Miniconda is a small, bootstrap version of Anaconda that includes only conda, Python. https://docs.conda.io/en/latest/miniconda.html – Ormetrom2354 Dec 23 '21 at 12:35

1 Answers1

4

Miniconda (the light, non-GUI version of Anaconda) gives you access to conda on the command line, and with that you can install R, along with some common packages, as follows:

conda install r r-essentials --channel conda-forge

And any further R packages you need:

conda install r-<package-name> --channel conda-forge

The "Conda" ecosystem is language-agnostic, it delivers whatever you ask for (if it exists in the repository) and installs the necessary platform binaries, but I would suggest creating a virtual environment specific to each "language platform", to ensure isolation.

Example:

conda create -n r_env r-essentials r-base

conda activate r_env

conda list

And work within this environment to run R and install new packages.

To leave the virtual environment:

conda deactivate