天天看點

python中繪制簡單圖形可以引入的庫是_在python中使用圖形庫matplotlib

matplotlib is a python 2D plotting library which produces publication quality figures in a variety of hardcopy formats and interactive environments across platforms. matplotlib can be used in python scripts, the python and ipython shell (ala MATLAB®* or Mathematica®†), web application servers, and six graphical user interface toolkits.

簡單了解就是一個python 的圖形繪制工具

這個工具的創始人已經在2012年因病去世,天妒英才啊。

官網:http://matplotlib.org/

主機:windows10 64bit

python 2.7.10

安裝方法:

python -m pip install -U pip setuptools

python -m pip install matplotlib

PS:感謝雙11,今天的網絡不錯,很快就下載下傳安裝好了。

安裝完成後在目錄:(我的py直接安裝在c根目錄下)

C:\Python27\Lib\site-packages\matplotlib\

Matplotlib 依賴于 Pillow ,Python官方的一個圖形庫

https://pypi.python.org/pypi/Pillow

在matplotlib的官網有很多例子可以學習

在部分案例中使用scipy的包,其官網

http://www.scipy.org/

scipy 統計,優化,整合,線性代數子產品,傅裡葉變換,信号和圖像處理,常微分方程求解

核心包:

安裝方法

python -m pip install --upgrade pip

pip install --user numpy scipy matplotlib ipython jupyter pandas sympy nose

我在安裝scipy,這個是遇到了錯誤

看了一下,感覺是:

pip does not work well for Windows because the standard pip package index site, PyPI, does not yet have Windows wheels for some packages, such as SciPy.

windows下需要自己下載下傳代碼編譯

Windows does not have any package manager analogous to that in Linux, so installing one of the scientific Python distributions mentioned above is preferred. However, if that is not an option, Christoph Gohlke provides pre-built Windows installers for many Python packages, including all of the core SciPy stack, which work extremely well.

後面再研究一下這個。