File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -2442,6 +2442,7 @@ def get_dummies(
2442
2442
)
2443
2443
if isinstance (self ._data .dtype , ArrowDtype ):
2444
2444
import pyarrow as pa
2445
+
2445
2446
dtype = ArrowDtype (pa .bool_ ())
2446
2447
string_series = input_series .apply (lambda x : str (x ) if not isna (x ) else x )
2447
2448
split_series = string_series .str .split (sep , expand = True ).stack ()
@@ -2489,10 +2490,10 @@ def get_dummies(
2489
2490
f"{ prefix [i ]} { prefix_sep } { col } "
2490
2491
for i , col in enumerate (result_df .columns )
2491
2492
]
2492
-
2493
+
2493
2494
if isinstance (self ._data , ABCIndex ):
2494
2495
return MultiIndex .from_frame (result_df )
2495
-
2496
+
2496
2497
result_df .attrs = self ._data .attrs
2497
2498
if dtype is not None and not sparse :
2498
2499
return result_df .astype (dtype )
You can’t perform that action at this time.
0 commit comments