Github user rxin commented on a diff in the pull request:
https://github.com/apache/spark/pull/5750#discussion_r29297150
--- Diff: python/pyspark/sql/functions.py ---
@@ -67,11 +73,48 @@ def _(col):
'sumDistinct': 'Aggregate function: returns the sum of distinct values
in the expression.',
}
+# math functions are found under another object therefore, they need to be
handled separately
+_math_functions = {
+ 'acos': 'Computes the cosine inverse of the given value; the returned
angle is in the range' +
+ '0.0 through pi.',
+ 'asin': 'Computes the sine inverse of the given value; the returned
angle is in the range' +
+ '-pi/2 through pi/2.',
+ 'atan': 'Computes the tangent inverse of the given value.',
+ 'atan2': 'Returns the angle theta from the conversion of rectangular
coordinates (x, y) to' +
+ 'polar coordinates (r, theta).',
+ 'cbrt': 'Computes the cube-root of the given value.',
+ 'ceil': 'Computes the ceiling of the given value.',
+ 'cos': 'Computes the cosine of the given value.',
+ 'cosh': 'Computes the hyperbolic cosine of the given value.',
+ 'exp': 'Computes the exponential of the given value.',
+ 'expm1': 'Computes the exponential of the given value minus one.',
+ 'floor': 'Computes the floor of the given value.',
+ 'hypot': 'Computes `sqrt(a^2^ + b^2^)` without intermediate overflow
or underflow.',
--- End diff --
i think u need to special case for binary columns. and add some tests for
some functions in python sql tests.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]