Skip to content

Commit

Permalink
Mention StreamSampling.jl in ReservoirSample docstring (#292)
Browse files Browse the repository at this point in the history
* Mention StreamSampling.jl in ReservoirSample docstring

* Update Project.toml
  • Loading branch information
Tortar authored Oct 1, 2024
1 parent b99b6cc commit b89a996
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name = "OnlineStats"
uuid = "a15396b6-48d5-5d58-9928-6d29437db91e"
version = "1.7.1"
version = "1.7.2"

[deps]
AbstractTrees = "1520ce14-60c1-5f80-bbc7-55ef81b5835c"
Expand Down
2 changes: 2 additions & 0 deletions src/stats/stats.jl
Original file line number Diff line number Diff line change
Expand Up @@ -644,6 +644,8 @@ nobs(o::Quantile) = nobs(o.eh)
Create a sample without replacement of size `k`. After running through `n` observations,
the probability of an observation being in the sample is `1 / n`.
If you need more advanced reservoir sampling methods consider using `StreamSampling.jl`.
# Example
fit!(ReservoirSample(100, Int), 1:1000)
Expand Down

0 comments on commit b89a996

Please sign in to comment.