@@ -498,9 +498,7 @@ def dataclasses_to_dicts(data):
498498# Conversion of Inputs to Arrays
499499
500500
501- def to_arrays (
502- data , columns , coerce_float : bool = False , dtype : Optional [DtypeObj ] = None
503- ):
501+ def to_arrays (data , columns , dtype : Optional [DtypeObj ] = None ):
504502 """
505503 Return list of arrays, columns.
506504 """
@@ -546,7 +544,7 @@ def to_arrays(
546544 data = [tuple (x ) for x in data ]
547545 content , columns = _list_to_arrays (data , columns )
548546
549- content , columns = _finalize_columns_and_data (content , columns , dtype , coerce_float )
547+ content , columns = _finalize_columns_and_data (content , columns , dtype )
550548 return content , columns
551549
552550
@@ -633,7 +631,6 @@ def _finalize_columns_and_data(
633631 content : np .ndarray ,
634632 columns : Optional [Union [Index , List ]],
635633 dtype : Optional [DtypeObj ],
636- coerce_float : bool ,
637634) -> Tuple [List [np .ndarray ], Union [Index , List [Axis ]]]:
638635 """
639636 Ensure we have valid columns, cast object dtypes if possible.
@@ -647,7 +644,7 @@ def _finalize_columns_and_data(
647644 raise ValueError (err ) from err
648645
649646 if len (content ) and content [0 ].dtype == np .object_ :
650- content = _convert_object_array (content , dtype = dtype , coerce_float = coerce_float )
647+ content = _convert_object_array (content , dtype = dtype )
651648 return content , columns
652649
653650
@@ -710,15 +707,14 @@ def _validate_or_indexify_columns(
710707
711708
712709def _convert_object_array (
713- content : List [Scalar ], coerce_float : bool = False , dtype : Optional [DtypeObj ] = None
710+ content : List [Scalar ], dtype : Optional [DtypeObj ] = None
714711) -> List [Scalar ]:
715712 """
716713 Internal function ot convert object array.
717714
718715 Parameters
719716 ----------
720717 content: list of processed data records
721- coerce_float: bool, to coerce floats or not, default is False
722718 dtype: np.dtype, default is None
723719
724720 Returns
@@ -728,7 +724,7 @@ def _convert_object_array(
728724 # provide soft conversion of object dtypes
729725 def convert (arr ):
730726 if dtype != np .dtype ("O" ):
731- arr = lib .maybe_convert_objects (arr , try_float = coerce_float )
727+ arr = lib .maybe_convert_objects (arr )
732728 arr = maybe_cast_to_datetime (arr , dtype )
733729 return arr
734730
0 commit comments