HyukjinKwon commented on a change in pull request #33882:
URL: https://github.com/apache/spark/pull/33882#discussion_r701552078
##########
File path: python/pyspark/pandas/namespace.py
##########
@@ -2747,13 +2747,19 @@ def merge(
@no_type_check
-def to_numeric(arg):
+def to_numeric(arg, errors="raise"):
"""
Convert argument to a numeric type.
Parameters
----------
arg : scalar, list, tuple, 1-d array, or Series
+ Argument to be converted.
+ errors : {'raise', 'coerce'}, default 'raise'
+ * If 'coerce', then invalid parsing will be set as NaN.
+ * If 'raise', then invalid parsing will raise an exception.
Review comment:
sorry last comment. Seems like it's going to work for other types but
not for pandas-on-Spark series. Can we add `ignrore` here with the note that it
doesn't work for pandas-on-Spark series?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]