English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية
Pandas Installation Guide
The Python core team plans to support2020 years1month1the day stops supporting Python 2.7.2018year12month31the final version before the day will support Python 2the last version.
from 2019year1month1Starting from the day, all Pandas versions only support Python 3.
For new beginners without experience, installing Pandas and other toolkits like NumPy and SciPy may be a bit difficult.
The simplest way is not to install Pandas directly, but to install Python and the most popular toolkits that make up the SciPy data science technology stack ( IPython, NumPy, Matplotlib, ...) collection AnacondaIt is a cross-platform (Linux, Mac OS X, Windows) Python distribution for data analysis and scientific computing.
After running the installer, users will be able to access any tools in the Pandas and SciPy toolkits without installing anything else or waiting for any software compilation, which is very convenient.
Can be installed through ActivePython HereFind Anacondainstallation instructions.
Can be installed through ActivePython HereFind as Anaconda distributionA complete list of some available software packages.
Another advantage of installing Anaconda is that it does not require administrator privileges. Anaconda can be installed in the user's home directory, and if you decide to remove Anaconda (simply delete the folder), it is very convenient.
Installing Pandas as part of the Anaconda distribution requires installing over a hundred packages and involves downloading several hundred megabytes of installation programs.
If you only want to install the packages you need or have limited internet bandwidth, installing Pandas with Miniconda may be a better solution.
Condais AnacondaThe package manager based on the distribution. It is a cross-platform and language-independent package manager (it can act like a combination of pip and virtualenv).
MinicondaIt allows you to create the smallest Python installation package and then install other software packages using Conda commands.
First, you need to install CondaDownload and run MinicondaIt will help you do this. The installation program can be found here.
The next step is to create a new conda environment. A conda environment is like a virtualenv, which allows you to specify a specific version of Python and the third-party libraries you need. Run the following command in the terminal window:
$ conda create -n name_of_my_env python
This will create a minimal environment that only installs Python. Place yourself in this environment (activate the environment):
$ source activate name_of_my_env
The command on Windows is:
$ activate name_of_my_env
最后一步是安装Pandas,可以使用以下命令完成:
$ conda install Pandas
The final step is to install Pandas, you can use the following command to complete it:
$ conda install Pandas2To install a specific version of Pandas:3
$ conda install Pandas=0.
0.
To install other packages, such as IPython:
$ conda install ipython
To install the complete Anaconda distribution:
$ conda install anaconda
$ conda install pip $ pip install django
From PyPI installation
All versions come with the pip tool.//pip is a Python package management tool that provides functions for searching, downloading, installing, and uninstalling Python packages. Currently if you are
www.python.org 2.7.9 + Download the latest version of the installation package, it is already equipped with this tool. 3.4+ Python
Or Python All versions come with the pip tool.//pip official website:/https:/You can use the following command to determine if it is installed:
pypi.org
project
You can use the following command to determine if it is installed: --Before installing with pip, you need to check if pip is already installed, the specific command is as follows:2pip You can use the following command to determine if it is installed:3 --Before installing with pip, you need to check if pip is already installed, the specific command is as follows:3pip
version # Python
.x version command//If you have not installed it yet, you can use the following method to install:/pip.py $ sudo python get-$ sudo python -$ curl https:-bootstrap.pypa.io-$ sudo python
o get3 pip.py $ sudo python get-$ sudo python
The version of Python used to run the installation script, pip is associated with that version, if it is Python 2.7Then execute the above command.3 Generally, pip corresponds to Python 3, pip
.x. It corresponds to Python
After installing pip, you can use the following command to install:
Can be installed through ActivePython HereFind ActivePythonInstallation instructions for version. Version2.7And3.5 It includes pandas.
The commands in this table will install Python from your distribution 3Version of Pandas. To install Python 2Version of Pandas, you may need to use python-Pandas package
Distribution Name | Status | Download / Repository Address | Installation Methods |
Debian | stable | official Debian repository | sudo apt-get install |
Debian & Ubuntu | unstable (latest packages) | NeuroDebian | |
Ubuntu | stable | official Ubuntu repository | sudo apt-get install python3-Pandas |
OpenSuse | stable | OpenSuse Repository | zypper in python3-Pandas |
Fedora | stable | official Fedora repository | dnf install python3-Pandas |
Centos/RHEL | stable | EPEL repository | yum install python3-Pandas |
$ pip install pandas $ python -i >>> pandaspd >>> df = pd.() >>> print(df) Empty DataFrame Columns: [] Index: []