title: Module 'rpy2.robjects.pandas2ri' has no attribute 'ri2py'
body: <p>I'm trying to convert R-dataframe to Python Pandas DataFrame.
  I use the following code:</p>
  
  <pre><code>from rpy2.robjects import pandas2ri
  pandas2ri.activate()
  r_dataframe = r_function(my_dataframe['Numbers'])
  print(r_dataframe)
  python_dataframe = pandas2ri.ri2py(r_dataframe)
  </code></pre>
  
  <p>The above code works well in Jupyter Notebook (Anaconda). But if I run this code through a <code>my_program.py</code> file through the terminal, I get an error:</p>
  
  <pre><code>:~$ python3 my_program.py
  Traceback (most recent call last):
    File "my_program.py", line 223, in &lt;module&gt;
      python_dataframe = pandas2ri.ri2py(r_dataframe)
  AttributeError: module 'rpy2.robjects.pandas2ri' has no attribute 'ri2py'
  </code></pre>
  
  <p>Line of code: <code>print(r_dataframe)</code> shows right result in the terminal.</p>
  
  <p>If I try to use code <code>print(dir(pandas2ri))</code> in Jupyter Notebook I get (<code>'ri2py'</code>):</p>
  
  <pre><code>['DataFrame', 'FactorVector', 'FloatSexpVector', 'INTSXP', 'ISOdatetime', 'IntSexpVector', 'IntVector', 'ListSexpVector', 'ListVector', 'OrderedDict', 'POSIXct', 'PandasDataFrame', 'PandasIndex', 'PandasSeries', 'SexpVector', 'StrSexpVector', 'StrVector', 'Vector', '__builtins__', '__cached__', '__doc__', '__file__', '__loader__', '__name__', '__package__', '__spec__', 'activate', 'as_vector', 'conversion', 'converter', 'datetime', 'deactivate', 'dt_O_type', 'dt_datetime64ns_type', 'get_timezone', 'numpy', 'numpy2ri', 'original_converter', 'os', 'pandas', 'py2ri', 'py2ri_categoryseries', 'py2ri_pandasdataframe', 'py2ri_pandasindex', 'py2ri_pandasseries', 'py2ro', 'pytz', 'recarray', 'ri2py', 'ri2py_dataframe', 'ri2py_floatvector', 'ri2py_intvector', 'ri2py_listvector', 'ri2py_vector', 'ri2ro', 'rinterface', 'ro', 'warnings']
  </code></pre>
  
  <p>And if I try to use the same code <code>print(dir(pandas2ri))</code> in Terminal I get (<code>'rpy2py'</code>):</p>
  
  <pre><code>['DataFrame', 'FactorVector', 'FloatSexpVector', 'ISOdatetime', 'IntSexpVector', 'IntVector', 'ListSexpVector', 'OrderedDict', 'POSIXct', 'PandasDataFrame', 'PandasIndex', 'PandasSeries', 'Sexp', 'SexpVector', 'StrSexpVector', 'StrVector', '__builtins__', '__cached__', '__doc__', '__file__', '__loader__', '__name__', '__package__', '__spec__', 'activate', 'as_vector', 'conversion', 'converter', 'datetime', 'deactivate', 'default_timezone', 'dt_O_type', 'get_timezone', 'is_datetime64_any_dtype', 'numpy', 'numpy2ri', 'original_converter', 'pandas', 'py2rpy', 'py2rpy_categoryseries', 'py2rpy_pandasdataframe', 'py2rpy_pandasindex', 'py2rpy_pandasseries', 'pytz', 'ri2py_vector', 'rinterface', 'rpy2py', 'rpy2py_dataframe', 'rpy2py_floatvector', 'rpy2py_intvector', 'rpy2py_listvector', 'tzlocal', 'warnings']
  </code></pre>
  
  <p>It turns out the developers have changed the name of the functions.</p>