Skip to content

Commit

Permalink
add docs
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewgazelka committed Oct 5, 2024
1 parent c3233d6 commit fa23718
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions daft/expressions/expressions.py
Original file line number Diff line number Diff line change
Expand Up @@ -2930,6 +2930,10 @@ def value_counts(self) -> Expression:
original list of type X, and the values are UInt64 counts representing
the number of times each element appears in the list.
Note:
This function does not work for nested types. For example, it will not produce a map
with lists as keys.
Example:
>>> import daft
>>> df = daft.from_pydict({"letters": [["a", "b", "a"], ["b", "c", "b", "c"]]})
Expand Down

0 comments on commit fa23718

Please sign in to comment.