forked from pandas-dev/pandas-stubs
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbase.pyi
91 lines (85 loc) · 2.5 KB
/
base.pyi
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
from typing import (
Generic,
Literal,
)
import numpy as np
from pandas import Index
from pandas.core.accessor import DirNamesMixin
from pandas.core.arrays import ExtensionArray
from pandas.core.arrays.categorical import Categorical
from pandas._typing import (
NaPosition,
NDFrameT,
Scalar,
SeriesAxisType,
npt,
)
class PandasObject(DirNamesMixin):
def __sizeof__(self) -> int: ...
class NoNewAttributesMixin:
def __setattr__(self, key, value) -> None: ...
class SelectionMixin(Generic[NDFrameT]):
def ndim(self) -> int: ...
def __getitem__(self, key): ...
class IndexOpsMixin:
__array_priority__: int = ...
def transpose(self, *args, **kwargs) -> IndexOpsMixin: ...
@property
def T(self) -> IndexOpsMixin: ...
@property
def shape(self) -> tuple: ...
@property
def ndim(self) -> int: ...
def item(self): ...
@property
def nbytes(self) -> int: ...
@property
def size(self) -> int: ...
@property
def array(self) -> ExtensionArray: ...
def to_numpy(
self,
dtype: npt.DTypeLike | None = ...,
copy: bool = ...,
na_value: Scalar = ...,
**kwargs,
) -> np.ndarray: ...
@property
def empty(self) -> bool: ...
def max(self, axis=..., skipna: bool = ..., **kwargs): ...
def min(self, axis=..., skipna: bool = ..., **kwargs): ...
def argmax(
self, axis: SeriesAxisType | None = ..., skipna: bool = ..., *args, **kwargs
) -> np.ndarray: ...
def argmin(
self, axis: SeriesAxisType | None = ..., skipna: bool = ..., *args, **kwargs
) -> np.ndarray: ...
def tolist(self) -> list: ...
def to_list(self) -> list: ...
def __iter__(self): ...
@property
def hasnans(self) -> bool: ...
def value_counts(
self,
normalize: bool = ...,
sort: bool = ...,
ascending: bool = ...,
bins=...,
dropna: bool = ...,
): ...
def nunique(self, dropna: bool = ...) -> int: ...
@property
def is_unique(self) -> bool: ...
@property
def is_monotonic_decreasing(self) -> bool: ...
@property
def is_monotonic_increasing(self) -> bool: ...
def factorize(
self, sort: bool = ...
) -> tuple[np.ndarray, np.ndarray | Index | Categorical]: ...
def searchsorted(
self, value, side: Literal["left", "right"] = ..., sorter=...
) -> int | list[int]: ...
def drop_duplicates(
self, *, keep: NaPosition | Literal[False] = ...
) -> IndexOpsMixin: ...