[//]: # (title: valueCounts) Return [`DataFrame`](DataFrame.md) containing counts of unique values in [`DataFrame`](DataFrame.md) or [`DataColumn`](DataColumn.md). ```kotlin valueCounts(sort = true, ascending = false, dropNA = false) [ { columns } ] ``` See [column selectors](ColumnSelectors.md) for how to select the columns for this operation. **Parameters:** * `sort: Boolean = true` — sort by count * `ascending: Boolean = false` — sort in ascending order * `dropNA: Boolean = true` — don't include counts of [`NA`](nanAndNa.md) values * `columns = all` — columns to use when counting unique combinations ```kotlin df.city.valueCounts() df.valueCounts { name and city } ```