Learn R Programming

seededlda (version 0.8.1)

divergence: Optimize the number of topics

Description

These functions help users to find the optimal number of topics for LDA.

Usage

divergence(x)

Arguments

x

a LDA model fitted by textmodel_seededlda() or textmodel_lda()

Details

divergence() computes the average Kullback–Leibler distance between all the pairs of topic vectors in x$phi. The divergence score maximizes when the chosen number of topic k is optimal (Deveaud et al., 2014).

References

Deveaud, Romain et al. (2014). "Accurate and Effective Latent Concept Modeling for Ad Hoc Information Retrieval". doi:10.3166/DN.17.1.61-84. Document Numérique.