# Example 1 ----------------------------------------------------------------
# We need to simulate a tree
set.seed(1231)
newtree <- sim_tree(1e3)
# Preprocessing the data
# Simulating
ans <- sim_fun_on_tree(
newtree,
psi = c(.01, .05),
mu_d = c(.90, .80),
mu_s = c(.1, .05),
Pi = .5,
eta = c(1, 1)
)
# Tabulating results
table(ans)
Run the code above in your browser using DataLab