]> gitweb.factorcode.org Git - factor.git/blob - extra/math/cardinality/cardinality-docs.factor
Switch to https urls
[factor.git] / extra / math / cardinality / cardinality-docs.factor
1 ! Copyright (C) 2012 John Benediktsson
2 ! See https://factorcode.org/license.txt for BSD license
3 USING: help.markup help.syntax layouts math sequences ;
4 IN: math.cardinality
5
6 HELP: trailing-zeros
7 { $values { "m" number } { "n" number } }
8 { $description "Counts the number of trailing 0 bits in " { $snippet "m" } ", returning " { $link fixnum-bits } " if the number is zero." } ;
9
10 HELP: estimate-cardinality
11 { $values { "seq" sequence } { "k" number } { "n" number } }
12 { $description "Estimates the number of unique elements in " { $snippet "seq" } "." $nl "The number " { $snippet "k" } " controls how many bits of hash to use, creating " { $snippet "2^k" } " buckets." } ;