Hierarchical Dirichlet Process HDP applied to censored data
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | ## Not run:
weights <- matrix(c(1,0,0,0,1,0,0,0,1), ncol=3)
data <- sim.data(n=100, J=10, weights)
G3 <- init.HDP(prior=list(mu=0, n=0.1, v=3, vs2=1*3), L=15,
J=length(unique(data@presentation$Sample)), thinning=50,
burnin = 5000, max_iter = 55000)
G3 <- MCMC.HDP(G3, data, 55000)
validate.HDP(G3, data)
plot.ICDF(G3@theta, G3@phi, G3@weights[,1], G3@L, grid=0:500,
distribution=data@presentation, xlim=500)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.