Skip to contents

Beta conjugacy at every node of the dyadic partition gives the posterior mean density in closed form (Sec. 3.7, 7.2.3).

Usage

morie_polya_tree_density(
  x,
  grid = NULL,
  levels = 6L,
  a_scale = 1,
  lo = NULL,
  hi = NULL
)

Arguments

x

numeric observations.

grid

evaluation points.

levels

depth of the dyadic partition.

a_scale

positive multiplier on \(a_m = a\_scale\,m^2\).

lo, hi

bounds of the partitioned interval.

Value

list: grid, density, levels, a_rule, absolutely_continuous_prior, mass, consistent_at, n, method.

Details

The choice of a_m decides whether the prior is usable. Constant \(a_m\) supports distributions SINGULAR with respect to Lebesgue measure, so no density exists to be consistent for; growing \(a_m\), with \(m^2\) standard, puts mass on absolutely continuous laws and the posterior is then Hellinger-consistent at any Lipschitz density. Mirrors morie.fn.gh_c7_6.

References

Ghosal and van der Vaart, Sec. 3.7 and 7.2.3.

Examples

set.seed(1)
morie_polya_tree_density(rnorm(200), levels = 4)$absolutely_continuous_prior
#> [1] TRUE