That is, learning the assignment of words to topics z given the observed words w by repeatedly sampling the latent variables z ij regarding the other values of z.
of using the collapsed Gibbs sampler for LDA, we can draw the values of θ and φ.