@@ -45,6 +45,8 @@ from pandas.core.indexes.multi import MultiIndex
4545from pandas .core .indexes .period import PeriodIndex
4646from pandas .core .indexes .timedeltas import TimedeltaIndex
4747from pandas .core .indexing import (
48+ _AtIndexer ,
49+ _iAtIndexer ,
4850 _iLocIndexer ,
4951 _IndexSliceTuple ,
5052 _LocIndexer ,
@@ -285,6 +287,44 @@ class _LocIndexerFrame(_LocIndexer, Generic[_T]):
285287 value : Scalar | NAType | NaTType | ArrayLike | Series | list | dict | None ,
286288 ) -> None : ...
287289
290+ class _iAtIndexerFrame (_iAtIndexer ):
291+ def __getitem__ (self , idx : tuple [int , int ]) -> Scalar : ...
292+ def __setitem__ (
293+ self ,
294+ idx : tuple [int , int ],
295+ value : Scalar | NAType | NaTType | None ,
296+ ) -> None : ...
297+
298+ class _AtIndexerFrame (_AtIndexer ):
299+ def __getitem__ (
300+ self ,
301+ idx : tuple [
302+ int
303+ | StrLike
304+ | Timestamp
305+ | tuple [Scalar , ...]
306+ | Callable [[DataFrame ], ScalarT ],
307+ int | StrLike | tuple [Scalar , ...],
308+ ],
309+ ) -> Scalar : ...
310+ def __setitem__ (
311+ self ,
312+ idx : (
313+ MaskType | StrLike | _IndexSliceTuple | list [ScalarT ] | IndexingInt | slice
314+ ),
315+ value : (
316+ Scalar
317+ | NAType
318+ | NaTType
319+ | ArrayLike
320+ | Series
321+ | DataFrame
322+ | list
323+ | Mapping [Hashable , Scalar | NAType | NaTType ]
324+ | None
325+ ),
326+ ) -> None : ...
327+
288328# With mypy 1.14.1 and python 3.12, the second overload needs a type-ignore statement
289329if sys .version_info >= (3 , 12 ):
290330 class _GetItemHack :
@@ -1591,13 +1631,13 @@ class DataFrame(NDFrame, OpsMixin, _GetItemHack):
15911631 axis : Axis = 0 ,
15921632 skipna : _bool = True ,
15931633 numeric_only : _bool = False ,
1594- ) -> Series : ...
1634+ ) -> Series [ int ] : ...
15951635 def idxmin (
15961636 self ,
15971637 axis : Axis = 0 ,
15981638 skipna : _bool = True ,
15991639 numeric_only : _bool = False ,
1600- ) -> Series : ...
1640+ ) -> Series [ int ] : ...
16011641 def mode (
16021642 self ,
16031643 axis : Axis = 0 ,
@@ -1683,7 +1723,7 @@ class DataFrame(NDFrame, OpsMixin, _GetItemHack):
16831723 def __iter__ (self ) -> Iterator [Hashable ]: ...
16841724 # properties
16851725 @property
1686- def at (self ): ... # Not sure what to do with this yet; look at source
1726+ def at (self ) -> _AtIndexerFrame : ...
16871727 @property
16881728 def columns (self ) -> Index [str ]: ...
16891729 @columns .setter # setter needs to be right next to getter; otherwise mypy complains
@@ -1695,7 +1735,7 @@ class DataFrame(NDFrame, OpsMixin, _GetItemHack):
16951735 @property
16961736 def empty (self ) -> _bool : ...
16971737 @property
1698- def iat (self ): ... # Not sure what to do with this yet; look at source
1738+ def iat (self ) -> _iAtIndexerFrame : ...
16991739 @property
17001740 def iloc (self ) -> _iLocIndexerFrame [Self ]: ...
17011741 @property
0 commit comments