I have pandas and rpy2 installed.
However the call to the rmagic in ipython does not work:
%load_ext rpy2.ipython /Users/user/.pyenv/versions/3.6.5/lib/python3.6/site-packages/rpy2/ipython/rmagic.py:73: UserWarning: The Python package 'pandas' is stronglyrecommended when using `rpy2.ipython`. Unfortunately it could not be loaded, but at least we found 'numpy'. "but at least we found 'numpy'.")))
By looking at the source file, I noticed that the failing import is the following:
from rpy2.robjects import pandas2ri
which fails with
20 import numpy 21 import pytz ---> 22 import tzlocal 23 import warnings 24 ModuleNotFoundError: No module named 'tzlocal'
I think the message of the failed import for rmagic is a bit misleading. Or maybe tzlocal should be included as a dependency.
python 3.6.5, pandas==0.22.0, rpy2==2.9.3