O'Reilly logo

NumPy Cookbook - Second Edition by Ivan Idris

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Installing RPy2

R is a popular scripting language used in statistics and data analysis. RPy2 is an interface between R and Python. We will install RPy2 in this recipe.

How to do it...

If you want to install RPy2 choose one of the following options:

  • Installing with pip or easy_install: RPy2 is available on PYPI, so we can install it with this command:
    $ easy_install rpy2
    

    Alternatively, we can use the following command:

    $ sudo pip install rpy2
    $ pip freeze|grep rpy2
    rpy2==2.4.2
    
  • Installing from source: We can install RPy2 from the tar.gz source:
    $ tar -xzf <rpy2_package>.tar.gz
    $ cd <rpy2_package>
    $ python setup.py build install
    

See also

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required