《Python数据分析基础教程:Numpy学习指南》 常用模块与方法简要记录

简介: 《Python数据分析基础教程:Numpy学习指南》 常用模块与方法简要记录

第三章 numpy的常用函数1.savetxt

2.loadtxt (converters): datetime.datetime.strptime [p46]

3.average

4.mean

5.max

6.min

7.ptp

8.median

9.msort/sort

10.var

11.diff

12.std

13.where

14:take

15:argmax ----- *

16:argmin ----- *

17.ravel

18.split\hsplit\vsplit

19.apply_along_axis

20.maximum ----- *

21.minimum ----- *

22.convolve

23.eye

24.zeros

25.ones

26.linspace

27.exp

28.fill

29.linalg.lstsq

30.dot

31.ones_like

32.intersect1d

33.vstack\hstack\dstack\column_stack\row_stack

34.concatenate

ndarray常用函数和属性ndarray的常用函数

1.mean

2.ravel

3.sum

4..clip

5.compress

6.prod

7.cumprod

8.tolist

9.astype

10.resh


ndarray的常用属性

1.ndim

2.size

3.itemsize

4.shape

5.dtype

6.nbytes

7.T

8.real

9.imag

10.flat

第四章 numpy的便捷函数1.diagonal

2.trace

3.cov

4.corrcoef

5.std ddof=1

6.polyfit

7.polyval

8.roots

9.polyder

10.sign

11.piecewise

12.vectorize

13.hanning

14.polysub

15.isreal

16.select

17.trim_zeros

第五章 矩阵和通用函数1.mat

① 专用字符串: " "行间隔, ";"列间隔

② 数组

2.bmat

3.frompyfunc

4.zeros_like

5.add.reduce

6.add.accumulate

7.add.reduceat

8.add.outer

9.add\subtract\multiply\divide\true_divide\floor_division

10."/" "//"

11.mod\%\remainder\fmod

12.matrix

第六章 深入Numpy模块1.np.dual

2.np.linalg.inv

3.np.mat 注意,矩阵乘法和数组乘法不相同,与数组dot方法相同

4.np.linalg.solve

5.np.linalg.eigvals

6.np.linalg.eig

7.np.linalg.svd

8.np.linalg.pinv

9.np.linalg.det

10.np.fft.fft

11.np.fft.ifft

12.np.all

13.np.linalg.fftshift

14.np.linalg.ifftshift

15.np.random.binomial

16.np.random.hypergeometirc

17.np.random.beta

chisquare

exponential

f

gamma

gumbel

laplace

lognormal

logistic

multivariate_nomal

noncentral_chisquare

noncentral_f

normal

第七章 Numpy专用函数1.np.sort

lexsort

argsort

ndarray.sort

msort

sort_complex

2.np.argmax

3.np.nanargmax

4.np.argmin

5.np.nanargmin

6.np.argwhere

7.np.searchsorted

8.np.extract

9.np.insert

10.np.nonzero

11.np.bartlett

12.np.blackman

13.np.hamming

14.np.hanning

15.np.kaiser

12.np.i0

13.np.sinc

第八章 质量控制1.np.testing.assert_almost_equal

2.np.testing.assert_approx_equal

3.np.testing.assert_array_almost_equal

4.np.testing.assert_array_equal

5.np.testing.assert_array_less

6.np.testing.assert_equal

7.np.testing.assert_raises

8.np.testing.assert_warns

9.np.testing.assert_string_equal

10.np.testing.assert_allclose

11.np.testing.assert_alloclose

12.np.testing.assert_array_almost_equal_nulp

13.np.testing.assert_array_max_ulp

14.import unittest

from numpy.testing.decorators import setastest

from numpy.testing.decorators import skipif

from numpy.testing.decorators import knownfailureif

from numpy.testing import decorate_methods

15.numpy.testing.decorators.deprecated

16.numpy.testing.decorators.knownfailureif

17.numpy.testing.decorators.setastest

18.numpy.testing.decorators.skipif

19.numpy.testing.decorators.slow

20.from numpy.testing import rundocs

第九章 使用Matplotlib1.import matplotlib.pyplot as plt

2.np.poly1d

3.plt.plot

4.plt.xlabel

5.plt.ylabel

6.plt.show

7.np.poly1d.deriv

8.plt.subplot

9.plt.title

10.plt.figure

11.plt.figure.add_subplot

12.axis.set_major_locator

13.axis.set_minor_locator

14.axis.set_major_fomatter

15.figure.autofmt_xdate

16.from datetime import date

17.date.today

18.plt.hist

19.plt.semilogx

20.plt.semilogy

21.plt.loglog

22.plt.scatter

23.figure.set_title

24.plt.grid

25.plt.fill_between

26.plt.legend

27.plt.annotate

28.np.meshgrid

29.plt.plot_surface

30.plt.contour/plt.contourf

31.np.random.rand

32. import matplotlib.animation as animation

33. animation.FuncAnimation

34. from mpl_toolkits.mplot3d import Axes3D

第十章 SciPy0.from scipy import stats

1. stats.norm.rvs

2.stats.norm.fit

3.stats.kurtosistest

4.stats.skewtest

5.stats.normaltest

6.stats.scoreatpercentile

7.stats.percentileofscore

8.stats.ttest_ind

9.stats.ks_2samp

10.from scikits.statsmodels.stattools import jarque_bera

11.from scipy import signal

signal.detrend

12.from scipy import fftpack

fftpack.fftshift

fftpack.rfft

ffpack.iffshift

ffpack.irfft

13.from scipy import optimize

optimize.leastsq

14.from scipy import integrate

integrate.quad

15.from scipy imprt interpolate

interpolate.interp1d

interpolate.interp2d

16.from scipy import ndimage

ndimage.median_filter

ndimage.rotate

ndimage.prewitt

17.from scipy import misc

image = misc.lena().astype(np.float)

18.plt.imshow(image,  cmap=plt.cm.gray)

19. from scipy.io import wavfile

wavfile.read

wavfile.write

20.np.tile

21.import urllib2

urllib2.urlopen


目录
相关文章
|
9月前
|
SQL 关系型数据库 数据库
Python SQLAlchemy模块:从入门到实战的数据库操作指南
免费提供Python+PyCharm编程环境,结合SQLAlchemy ORM框架详解数据库开发。涵盖连接配置、模型定义、CRUD操作、事务控制及Alembic迁移工具,以电商订单系统为例,深入讲解高并发场景下的性能优化与最佳实践,助你高效构建数据驱动应用。
1004 7
|
9月前
|
JSON 算法 API
Python中的json模块:从基础到进阶的实用指南
本文深入解析Python内置json模块的使用,涵盖序列化与反序列化核心函数、参数配置、中文处理、自定义对象转换及异常处理,并介绍性能优化与第三方库扩展,助你高效实现JSON数据交互。(238字)
714 4
|
9月前
|
Java 调度 数据库
Python threading模块:多线程编程的实战指南
本文深入讲解Python多线程编程,涵盖threading模块的核心用法:线程创建、生命周期、同步机制(锁、信号量、条件变量)、线程通信(队列)、守护线程与线程池应用。结合实战案例,如多线程下载器,帮助开发者提升程序并发性能,适用于I/O密集型任务处理。
784 0
|
9月前
|
XML JSON 数据处理
超越JSON:Python结构化数据处理模块全解析
本文深入解析Python中12个核心数据处理模块,涵盖csv、pandas、pickle、shelve、struct、configparser、xml、numpy、array、sqlite3和msgpack,覆盖表格处理、序列化、配置管理、科学计算等六大场景,结合真实案例与决策树,助你高效应对各类数据挑战。(238字)
1232 0
|
9月前
|
存储 Java 数据处理
(numpy)Python做数据处理必备框架!(一):认识numpy;从概念层面开始学习ndarray数组:形状、数组转置、数值范围、矩阵...
Numpy是什么? numpy是Python中科学计算的基础包。 它是一个Python库,提供多维数组对象、各种派生对象(例如掩码数组和矩阵)以及用于对数组进行快速操作的各种方法,包括数学、逻辑、形状操作、排序、选择、I/0 、离散傅里叶变换、基本线性代数、基本统计运算、随机模拟等等。 Numpy能做什么? numpy的部分功能如下: ndarray,一个具有矢量算术运算和复杂广播能力的快速且节省空间的多维数组 用于对整组数据进行快速运算的标准数学函数(无需编写循环)。 用于读写磁盘数据的工具以及用于操作内存映射文件的工具。 线性代数、随机数生成以及傅里叶变换功能。 用于集成由C、C++
710 1
|
9月前
|
Java 数据处理 索引
(numpy)Python做数据处理必备框架!(二):ndarray切片的使用与运算;常见的ndarray函数:平方根、正余弦、自然对数、指数、幂等运算;统计函数:方差、均值、极差;比较函数...
ndarray切片 索引从0开始 索引/切片类型 描述/用法 基本索引 通过整数索引直接访问元素。 行/列切片 使用冒号:切片语法选择行或列的子集 连续切片 从起始索引到结束索引按步长切片 使用slice函数 通过slice(start,stop,strp)定义切片规则 布尔索引 通过布尔条件筛选满足条件的元素。支持逻辑运算符 &、|。
412 0
|
11月前
|
机器学习/深度学习 API 异构计算
JAX快速上手:从NumPy到GPU加速的Python高性能计算库入门教程
JAX是Google开发的高性能数值计算库,旨在解决NumPy在现代计算需求下的局限性。它不仅兼容NumPy的API,还引入了自动微分、GPU/TPU加速和即时编译(JIT)等关键功能,显著提升了计算效率。JAX适用于机器学习、科学模拟等需要大规模计算和梯度优化的场景,为Python在高性能计算领域开辟了新路径。
1003 0
JAX快速上手:从NumPy到GPU加速的Python高性能计算库入门教程
|
机器学习/深度学习 数据处理 Python
从NumPy到Pandas:轻松转换Python数值库与数据处理利器
从NumPy到Pandas:轻松转换Python数值库与数据处理利器
471 1
|
11月前
|
存储 数据采集 数据处理
Pandas与NumPy:Python数据处理的双剑合璧
Pandas与NumPy是Python数据科学的核心工具。NumPy以高效的多维数组支持数值计算,适用于大规模矩阵运算;Pandas则提供灵活的DataFrame结构,擅长处理表格型数据与缺失值。二者在性能与功能上各具优势,协同构建现代数据分析的技术基石。
812 0
|
机器学习/深度学习 数据处理 计算机视觉
NumPy实践宝典:Python高手教你如何轻松玩转数据处理!
【8月更文挑战第22天】NumPy是Python科学计算的核心库,专长于大型数组与矩阵运算,并提供了丰富的数学函数。首先需安装NumPy (`pip install numpy`)。之后可通过创建数组、索引与切片、执行数学与逻辑运算、变换数组形状及类型、计算统计量和进行矩阵运算等操作来实践学习。NumPy的应用范围广泛,从基础的数据处理到图像处理都能胜任,是数据科学领域的必备工具。
282 0

热门文章

最新文章

推荐镜像

更多