Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Returns the kurtosis of the values in a group.
Syntax
from pyspark.sql import functions as sf
sf.kurtosis(col)
Parameters
| Parameter | Type | Description |
|---|---|---|
col |
pyspark.sql.Column or column name |
Target column to compute on. |
Returns
pyspark.sql.Column: kurtosis of given column.
Examples
from pyspark.sql import functions as sf
df = spark.createDataFrame([[1],[1],[2]], ["c"])
result = df.select(sf.kurtosis(df.c)).collect()[0][0]
spark.createDataFrame([(result < -1.49 and result > -1.51,)], ["within_expected_range"]).show()
+---------------------+
|within_expected_range|
+---------------------+
| true|
+---------------------+