Skip to content

Commit 163cebd

Browse files
committed
MAINT: Update frame stata io
1 parent 34efdbc commit 163cebd

File tree

1 file changed

+15
-7
lines changed

1 file changed

+15
-7
lines changed

pandas-stubs/core/frame.pyi

Lines changed: 15 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,10 @@ from pandas._typing import (
4848
Axes,
4949
Axis,
5050
AxisType,
51+
CompressionOptions,
5152
Dtype,
5253
DtypeNp,
54+
FilePath,
5355
FilePathOrBuffer,
5456
FilePathOrBytesBuffer,
5557
GroupByObjectNonScalar,
@@ -67,8 +69,10 @@ from pandas._typing import (
6769
Scalar,
6870
ScalarT,
6971
SeriesAxisType,
72+
StorageOptions,
7073
StrLike,
7174
T as TType,
75+
WriteBuffer,
7276
np_ndarray_bool,
7377
np_ndarray_str,
7478
num,
@@ -236,15 +240,19 @@ class DataFrame(NDFrame, OpsMixin):
236240
) -> np.recarray: ...
237241
def to_stata(
238242
self,
239-
path: FilePathOrBuffer,
240-
convert_dates: dict | None = ...,
243+
path: FilePath | WriteBuffer[bytes],
244+
convert_dates: dict[Hashable, str] | None = ...,
241245
write_index: _bool = ...,
242-
byteorder: _str | Literal["<", ">", "little", "big"] | None = ...,
243-
time_stamp=...,
246+
byteorder: Literal["<", ">", "little", "big"] | None = ...,
247+
time_stamp: _dt.datetime | None = ...,
244248
data_label: _str | None = ...,
245-
variable_labels: dict | None = ...,
246-
version: int = ...,
247-
convert_strl: list[_str] | None = ...,
249+
variable_labels: dict[Hashable, str] | None = ...,
250+
version: int | None = ...,
251+
convert_strl: list[HashableT] | None = ...,
252+
compression: CompressionOptions = ...,
253+
storage_options: StorageOptions = ...,
254+
*,
255+
value_labels: dict[Hashable, dict[float, str]] | None = ...,
248256
) -> None: ...
249257
def to_feather(self, path: FilePathOrBuffer, **kwargs) -> None: ...
250258
@overload

0 commit comments

Comments
 (0)