DPM.HODC(v, pvalue,
DPM.mcmc=list(nburn=2000,nsave=1,
nskip=0,ndisplay=10),
DPM.prior=list(a0=2,b0=1,m2=rep(0,1),
s2=diag(100000,1),
psiinv2=solve(diag(0.5,1)),
nu1=4,nu2=4,tau1=1,tau2=100))mcmc of function DPdensity() in DPpackage for details; the default setting is DPM.mcmc=list(nburn=2000,nsave=1,nskip=0,ndisplay=10)prior of function DPdensity() in DPpackage for details; the default setting is prior2DPdensity to estimate the marginal density of the testing statistics r, converted from p-values, using a mixture of normal densities without incorporating the network information. Furthermore, it implements the HODC algorithm to classify density components into two clusters. We refer to them as the unimportant cluster and the important cluster, where the important cluster has a larger mean than the unimportant cluster.
Zhou Lan, Jian Kang, Tianwei Yu, Yize Zhao, BANFF: an R package for network identifications via Bayesian nonparametric mixture models, working paper.
###random make the density
rstat=c(rnorm(50,mean=1),rnorm(50,mean=2),rnorm(100,mean=4)
,rnorm(100,mean=8))
###transformed into pvalue
pvalue=pnorm(-rstat)
DPMHODC=DPM.HODC(v=5,pvalue)
Run the code above in your browser using DataLab