1

I'm trying to install reticulate but it's not working, I get this error message : Error 1 occurred creating conda environment. How can I fix this please.

Code :

library(reticulate)
repl_python()
Phil
  • 7,287
  • 3
  • 36
  • 66

1 Answers1

0

Reticulate needs an conda or another virtual environment. To investigate the source of the error message, I would check whether and which python version is per default used via py_config().

if not found, try to re-create the environment via conda_create("r-reticulate"). and then specify which environment to use via use_condaenv("r-reticulate").

Helpful links for installation and setup are rstudio.github.io/reticulate and subsection on conda-tools

Example output for py_config()

python:         ~/AppData/Local/r-miniconda/envs/r-reticulate/python.exe
libpython:      ~/AppData/Local/r-miniconda/envs/r-reticulate/python36.dll
pythonhome:     ~/AppData/Local/r-miniconda/envs/r-reticulate
version:        3.6.13 |Anaconda, Inc.| (default, Mar 16 2021, 11:37:27) [MSC v.1916 64 bit (AMD64)]
Architecture:   64bit
numpy:          ~/AppData/Local/r-miniconda/envs/r-reticulate/Lib/site-packages/numpy
numpy_version:  1.19.5
Manuela R.
  • 63
  • 7