0

I was trying to install some packages in R and I have run into an error:

Error: package or namespace load failed for ‘leiden’:
 .onAttach failed in attachNamespace() for 'leiden', details:
  call: py_module_import(module, convert = convert)
  error: ModuleNotFoundError: No module named 'pandas'

This is strange to me because I definitely have pandas:

$ conda list | grep pandas
pandas                    1.0.1            py37h0573a6f_0

Also which python seems to give me my anaconda installation:

/home/usrname/anaconda3/bin/python

I am installing these packages on WSL (Windows Subsystem for Linux) Ubuntu.

Any advice appreciated.

Connorr.0
  • 97
  • 9

1 Answers1

0

I ended up finding another issue with a similar problem. Turns out I needed to activate the conda r-reticulate environment.

Take a look at a similar question here: Python in R - Error: could not find a Python environment for /usr/bin/python

Connorr.0
  • 97
  • 9