Use the count() method to return column-wise count of a DataFrame.
Example here is for count() as Regular Aggregate function. For count() as Time Series Aggregate, refer to count() in Time Series Aggregate Mode.
Example
>>> df = DataFrame("employee_info") >>> df first_name marks dob joined_date employee_no 100 abcd None None None 101 abcde None None 1902-05-12 112 None None None 2018-05-12
>>> df1 = df.select(['employee_no', 'first_name', 'marks']) >>> df1.count() count_employee_no count_first_name count_marks 0 3 2 0