Python numpy备忘

numpy

ndarray

Help on class ndarray in module numpy:

class ndarray(builtins.object)
| ndarray(shape, dtype=float, buffer=None, offset=0,
| strides=None, order=None)
|
| An array object represents a multidimensional, homogeneous array
| of fixed-size items. An associated data-type object describes the
| format of each element in the array (its byte-order, how many bytes it
| occupies in memory, whether it is an integer, a floating point number,
| or something else, etc.)
|
| Arrays should be constructed using array, zeros or empty (refer
| to the See Also section below). The parameters given here refer to
| a low-level method (ndarray(...)) for instantiating an array.

dtype

Create a data type object.
A numpy array is homogeneous, and contains elements described by a dtype object. A dtype object can be constructed from different combinations of fundamental numeric types.

pandas

Series

由数据标签(索引)和数据组成
python2 order
python3 sort_values

DataFrame

python2 ix
python3 loc iloc

上一篇
下一篇