Dataframe 0.12 Help

count

Counts the number of rows.

df.count()

Pass a row condition to count only the number of rows that satisfy that condition:

df.count { age > 15 }

When count is used in groupBy or pivot aggregations, it counts rows for every data group:

df.groupBy { city }.count() df.pivot { city }.count { age > 18 } df.pivot { name.firstName }.groupBy { name.lastName }.count()
Last modified: 22 January 2024