Open bakkot opened 5 months ago
This has Random.pickFromList, which is a good and useful function when your list is of known length (though a bad name). But when it's not, you can still usefully sample from it (although it's O(n) to do so). Should we expose that functionality?
Random.pickFromList
O(n)
Yeah, some ability to reservoir sample would be interesting (and very non-trivial to do by hand!)
This has
Random.pickFromList
, which is a good and useful function when your list is of known length (though a bad name). But when it's not, you can still usefully sample from it (although it'sO(n)
to do so). Should we expose that functionality?