Accordingly, the posterior probability of node Zij belongs to community Ck is P(Ck|Zij;dij;αijk;βij;εijk), and the estimated parameters are εijk and βij. As BM is suitable for the situation where the variables for classification are parametric variables, it is used to obtain this posterior probability . To sample X, in order to judge its output, we need to calculate the posterior probability P(Ck|Zij;dij;αijk;βij;εijk), then decide the community which Zij belongs to. According to Bayesian formula, we have P(Ck|Zij;dij;αijk;βij;εijk)=P(Ck|dij;αijk;βij;εijk)P(Zij|Ck;dij;αijk;βij;εijk)P(Zij|dij;αijk;βij;εijk)(7)