pandas: powerful Python data analysis toolkit - 0.7.1__getitem__ for standard use cases • Avoid Index dict creation in some cases (i.e. when getting slices, etc.), regression from prior versions • Friendlier error message in setup.py if NumPy not installed ’something’ The Series name will be assigned automatically in many cases, in particular when taking 1D slices of DataFrame as you will see below. 5.2 DataFrame DataFrame is a 2-dimensional labeled data structure for those familiar with implementing class behavior in Python) is selecting out lower-dimensional slices. Thus, • Series: series[label] returns a scalar value • DataFrame: frame[colname] returns a Series0 码力 | 281 页 | 1.45 MB | 1 年前3
pandas: powerful Python data analysis toolkit - 0.7.2__getitem__ for standard use cases • Avoid Index dict creation in some cases (i.e. when getting slices, etc.), regression from prior versions • Friendlier error message in setup.py if NumPy not installed ’something’ The Series name will be assigned automatically in many cases, in particular when taking 1D slices of DataFrame as you will see below. 5.2 DataFrame DataFrame is a 2-dimensional labeled data structure for those familiar with implementing class behavior in Python) is selecting out lower-dimensional slices. Thus, • Series: series[label] returns a scalar value • DataFrame: frame[colname] returns a Series0 码力 | 283 页 | 1.45 MB | 1 年前3
pandas: powerful Python data analysis toolkit - 0.7.3__getitem__ for standard use cases • Avoid Index dict creation in some cases (i.e. when getting slices, etc.), regression from prior versions • Friendlier error message in setup.py if NumPy not installed ’something’ The Series name will be assigned automatically in many cases, in particular when taking 1D slices of DataFrame as you will see below. 5.2 DataFrame DataFrame is a 2-dimensional labeled data structure for those familiar with implementing class behavior in Python) is selecting out lower-dimensional slices. Thus, • Series: series[label] returns a scalar value • DataFrame: frame[colname] returns a Series0 码力 | 297 页 | 1.92 MB | 1 年前3
pandas: powerful Python data analysis toolkit - 0.14.0read_excel uses 0 as the default sheet (GH6573) • iloc will now accept out-of-bounds indexers for slices, e.g. a value that exceeds the length of the object being indexed. These will be excluded. This will can provide any of the selectors as if you are indexing by label, see Selection by Label, including slices, lists of labels, labels, and boolean indexers. You can use slice(None) to select all the contents C3 D0 249 248 251 250 D1 253 252 255 254 [64 rows x 4 columns] Basic multi-index slicing using slices, lists, and labels. 14 Chapter 1. What’s New pandas: powerful Python data analysis toolkit, Release0 码力 | 1349 页 | 7.67 MB | 1 年前3
pandas: powerful Python data analysis toolkit - 0.12(GH4215) • Fixed the legend displaying in DataFrame.plot(kind=’kde’) (GH4216) • Fixed bug where Index slices weren’t carrying the name attribute (GH4226) • Fixed bug in initializing DatetimeIndex with an array labels [’a’, ’b’, ’c’] – A slice object with labels ’a’:’f’, (note that contrary to usual python slices, both the start and the stop are included!) – A boolean array See more at Selection by Label • useful when dealing with mixed positional and label based hierarchial indexes. As using integer slices with .ix have different behavior depending on whether the slice is interpreted as position based0 码力 | 657 页 | 3.58 MB | 1 年前3
pandas: powerful Python data analysis toolkit - 0.17.0with a np.datetime64 (GH9516) • Incorrect dtypes inferred on datetimelike looking Series & on .xs slices (GH9477) • Items in Categorical.unique() (and s.unique() if s is of dtype category) now appear in today() and both have tz as a possible argument. (GH9000) • Fix negative step support for label-based slices (GH8753) Old behavior: In [1]: s = pd.Series(np.arange(3), ['a', 'b', 'c']) Out[1]: a 0 b 1 c read_excel uses 0 as the default sheet (GH6573) • iloc will now accept out-of-bounds indexers for slices, e.g. a value that exceeds the length of the object being indexed. These will be excluded. This will0 码力 | 1787 页 | 10.76 MB | 1 年前3
pandas: powerful Python data analysis toolkit - 0.13.1to sparse), so might be somewhat inefficient – enable setitem on SparseSeries for boolean/integer/slices – SparsePanels implementation is unchanged (e.g. not using BlockManager, needs work) • added ftypes (GH4215) • Fixed the legend displaying in DataFrame.plot(kind=’kde’) (GH4216) • Fixed bug where Index slices weren’t carrying the name attribute (GH4226) • Fixed bug in initializing DatetimeIndex with an array labels [’a’, ’b’, ’c’] – A slice object with labels ’a’:’f’, (note that contrary to usual python slices, both the start and the stop are included!) – A boolean array See more at Selection by Label •0 码力 | 1219 页 | 4.81 MB | 1 年前3
pandas: powerful Python data analysis toolkit - 0.15today() and both have tz as a possible argument. (GH9000) • Fix negative step support for label-based slices (GH8753) Old behavior: In [1]: s = pd.Series(np.arange(3), [’a’, ’b’, ’c’]) Out[1]: a 0 b 1 c read_excel uses 0 as the default sheet (GH6573) • iloc will now accept out-of-bounds indexers for slices, e.g. a value that exceeds the length of the object being indexed. These will be excluded. This will can provide any of the selectors as if you are indexing by label, see Selection by Label, including slices, lists of labels, labels, and boolean indexers. You can use slice(None) to select all the contents0 码力 | 1579 页 | 9.15 MB | 1 年前3
pandas: powerful Python data analysis toolkit - 0.15.1read_excel uses 0 as the default sheet (GH6573) • iloc will now accept out-of-bounds indexers for slices, e.g. a value that exceeds the length of the object being indexed. These will be excluded. This will can provide any of the selectors as if you are indexing by label, see Selection by Label, including slices, lists of labels, labels, and boolean indexers. You can use slice(None) to select all the contents New pandas: powerful Python data analysis toolkit, Release 0.15.1 Basic multi-index slicing using slices, lists, and labels. In [54]: df.loc[(slice(’A1’,’A3’),slice(None), [’C1’,’C3’]),:] Out[54]: lvl00 码力 | 1557 页 | 9.10 MB | 1 年前3
pandas: powerful Python data analysis toolkit - 0.19.0with a np.datetime64 (GH9516) • Incorrect dtypes inferred on datetimelike looking Series & on .xs slices (GH9477) • Items in Categorical.unique() (and s.unique() if s is of dtype category) now appear in today() and both have tz as a possible argument. (GH9000) • Fix negative step support for label-based slices (GH8753) Old behavior: In [1]: s = pd.Series(np.arange(3), ['a', 'b', 'c']) Out[1]: a 0 b 1 c read_excel uses 0 as the default sheet (GH6573) • iloc will now accept out-of-bounds indexers for slices, e.g. a value that exceeds the length of the object being indexed. These will be excluded. This will0 码力 | 1937 页 | 12.03 MB | 1 年前3
共 37 条
- 1
- 2
- 3
- 4













