prune {FVDDPpkg} | R Documentation |
Reduce the size of Fleming-Viot Dependent Dirichlet Processes
Description
Reduce the size of Fleming-Viot Dependent Dirichlet Processes
Usage
prune(fvddp, eps)
Arguments
fvddp |
An object of class |
eps |
The value behold which the weights are removed, with their components
of the mixture. |
Value
An fvddp
list of smaller size of the input. Precisely, the components
whose weight goes below the treshold eps
will be removed: the vector w
and
the matrix M
will have a lower amount of rows; if the latter will include all-zero
columns, they will be removed.
References
Ascolani F, Lijoi A, Ruggiero M (2023). “Smoothing distributions for conditional Fleming–Viot and Dawson–Watanabe diffusions.” Bernoulli, 29(2), 1410 – 1434. doi:10.3150/22-BEJ1504.
Examples
#create a large process
FVDDP = initialize(3, function(x) rexp(x, 4),
function(x) dexp(x, 4), FALSE)
FVDDP = update(FVDDP, c(rep(rexp(1, 3), 7), rep(rexp(1, 5), 5), rexp(1, 7), 3))
FVDDP = propagate(FVDDP, 1)
prune(fvddp = FVDDP, eps = 1e-4)
[Package FVDDPpkg version 0.1.2 Index]