Linux under source code compilation installation Rpy2

Source: Internet
Author: User

R (also known as R) is an open source cross-platform numerical statistics and numerical graphical presentation tool. Rpy2 is a third-party library that Python calls R directly, enabling objects that use Python to read R, methods to call R, and Python and r data structure transformations. Here is the main introduction in the absence of the network, the source code installation Rpy2 Some methods to make a memo.
1. Python installation$wgetHttps//www.python.org/ftp/python/2.7.6/Python-2.7.6.tgz
$TarZVXF python-2.7.6. tgz
$ CD python-2.7.6
$./configure--prefix=/ifs1/ngb_db/shenweiyan/localsoft/tools/python-2.7.6
$ Make&& MakeInstallView Code

python installs the user environment variable ~/.BASHRC to specify the path to Python: (thereafter the associated package installation will automatically be installed under the site-packages that the environment variable points to, no need to specify otherwise.) )Export path="/ifs1/ngb_db/shenweiyan/localsoft/tools/python-2.7.6/bin: $PATH


2, Setuptools installationSetuptools is a Python package management tool that helps us to create and distribute Python packages more simply, especially with dependencies. When we need to install a third-party Python package, we may use Easy_installLcommand. Easy_install is a command from the Setuptools package developed by the Peak (Python Enterprise application kit), so use Easy_ The install is actually calling Setuptools to complete the installation of the module. =wgetHttps//Pypi.python.org/packages/source/s/setuptools/setuptools-18.4.tar.gz#md5=214c6c43bd7035e870c1beab402c48e7-- No-check-certificate
=TarZVXF setuptools-18.4.Tar. gz
= = CD setuptools-18.4
= = Python setup.pyInstall(Easy_install is installed by default under the Python path specified by the environment variable:/ifs1/ngb_db/shenweiyan/localsoft/tools/python-2.7.6/bin)View Code

3. Install Rpy2 Dependency Packagethe installation of the RPY2 package depends on the installation of the Singledispatch package, and the Singledispatch package is dependent on the six package. =wgetHttps//Pypi.python.org/packages/source/s/six/six-1.10.0.tar.gz#md5=34eed507548117b2ab523ab14b2f8b55-- No-check-certificate
= = CD six-1.10.0
= = Python setup.pyInstall
=wgetHttps//pypi.python.org/packages/source/s/singledispatch/singledispatch-3.4.0.3.tar.gz#md5= AF2FC6A3D6CC5A02D0BF54D909785FCB--no-check-certificate
=TarZVXF singledispatch-3.4.0.3.Tar. gz
= = CD singledispatch-3.4.0.3
= = Python setup.pyInstallView Code

4, R installation

Linux under the source code compilation installation, not detailed here, detailed installation information refer to "Linux under the R compilation installation."

RPY2 installation needs to specify the path of the R software, otherwise the following error will occur:error:tried to guess R's HOME but no command (r) in the path.

Export path="/ifs1/ngb_db/shenweiyan/localsoft/tools/r-3.1.2/bin: $PATH"

5, RPY2 Installation
=wgetHttps//pypi.python.org/packages/source/r/rpy2/rpy2-2.7.2.tar.gz--no-check-certificate
=TarZVXF rpy2-2.7.2.Tar. gz
= = CD rpy2-2.7.2
= = Python setup.pyInstallView Code

The rpy2 installation is successful as shown below:

OK, problem solving!!!

Linux under source code compilation installation Rpy2

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.