RubyFlow The Ruby and Rails community linklog

Algorithms Every Programmer Should Know: Reservoir Sampling

I wrote and annotated a small RubyGem to explain the math behind reservoir sampling.

If you’ve ever wondered about the most efficient way to sample from an ActiveRecord query, this post is for you.

Post a comment

You can use basic HTML markup (e.g. <a>) or Markdown.

As you are not logged in, you will be
directed via GitHub to signup or sign in