W3cubDocs

/Nushell

dfr n-unique for dataframe

Counts unique values.

Signature

> dfr n-unique {flags}

Input/output types:

input output
any any

Examples

Counts unique values

> [1122334] |dfr into-df|dfr n-unique
╭───┬──────────────╮
# │ count_unique │
├───┼──────────────┤
04
╰───┴──────────────╯

Creates a is n-unique expression from a column

>dfr cola|dfr n-unique

Tips: Dataframe commands were not shipped in the official binaries by default, you have to build it with --features=dataframe flag

Copyright © 2019–2023 The Nushell Project DevelopersLicensed under the MIT License.
https://www.nushell.sh/commands/docs/dfr_n-unique.html