We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0ba8a95 commit 217da39Copy full SHA for 217da39
src/counts.jl
@@ -389,9 +389,10 @@ end
389
390
"""
391
countmap(x; alg = :auto)
392
+ countmap(x::AbstractVector, w::AbstractVector{<:Real}; alg = :auto)
393
394
Return a dictionary mapping each unique value in `x` to its number
-of occurrences.
395
+of occurrences. A vector of weights `w` can be provided when `x` is a vector.
396
397
- `:auto` (default): if `StatsBase.radixsort_safe(eltype(x)) == true` then use
398
`:radixsort`, otherwise use `:dict`.
0 commit comments