Skip to contents

Returns \(\alpha H_n = \alpha \sum_{i=1}^{n} 1 / i\), the expected number of distinct features ("dishes") sampled by n customers in a one-parameter Indian buffet process.

Usage

morie_gh_ibp_expected_dishes(n, alpha)

Arguments

n

number of customers (positive integer)

alpha

mass parameter of the Indian buffet process (positive)

Value

numeric scalar expected number of distinct features

References

Ghosal, S. and van der Vaart, A. (2017). Fundamentals of Nonparametric Bayesian Inference. Cambridge University Press.

Examples

morie_gh_ibp_expected_dishes(n = 10, alpha = 3)
#> [1] 8.786905