Note. Adapted from pyLDAvis (Sievert & Shirley, 2014, see codes here).