Questions tagged [latent-dirichlet-alloc]

Latent Dirichlet Allocation (LDA) is an unsupervised, statistical approach to document modeling that discovers latent semantic topics in large collections of text. (Do NOT use this for Linear Discriminant Analysis.)

Filter by
Sorted by
Tagged with
2 votes
1 answer
366 views

Why does Latent Dirichlet Allocation seems to work with greedy selection but not with Gibbs sampling?

I tried to implement my own LDA program in python, while following this tutorial. When I use gibbs sampling, the program assigns all words to a particular topic on convergence. When I greedily ...
user avatar
30 votes
4 answers
22k views

R packages for performing topic modeling / LDA: just `topicmodels` and `lda` [closed]

It seems to me that only two R packages are able to perform Latent Dirichlet Allocation: One is lda, authored by Jonathan Chang; and the other is ...
user avatar
  • 2,657
7 votes
1 answer
6k views

Reasonable hyperparameter range for Latent Dirichlet Allocation?

What are good ranges for the hyperparameters $\alpha$ and $\beta$ (explained well here) in LDA? I appreciate hyperparameter tuning always depends on the use case, data, content of documents etc., but ...
user avatar
  • 1,114
7 votes
1 answer
5k views

How does LDA (Latent Dirichlet Allocation) assign a topic-distribution to a new document?

I am new to topic modeling and read about LDA and NMF (Non-negative Matrix Factorization). I understand the training process work. Let's say I have 100 documents and I want to train an LDA for these ...
user avatar
  • 71
4 votes
1 answer
229 views

Gibbs sampling in Hierarchically Supervised LDA (HSLDA)

TL;DR In the HSLDA paper by Perotte et al, the posterior conditional distribution of $z_{d,n}$ for Gibbs Sampling is specified as: \begin{equation*} p(z_{d,n}=k| \mathbf{z}_{-d,n}, \mathbf{a}, \...
user avatar
  • 516
4 votes
1 answer
7k views

Why does lower perplexity indicate better generalization performance?

In the seminal paper on Latent Dirichlet Allocation, the authors state that, A lower perplexity score indicates better generalization performance. $perplexity(D_{test})=exp\Big\{-\frac{\sum_{d=1}^{M}...
user avatar
  • 3,152
3 votes
1 answer
1k views

Understanding the role of document size parameters in Latent Dirichlet Allocation

I am writing a pymc3-based implementation of Latent Dirichlet Allocation, and am referencing this CrossValidated answer (modified for pymc3) as well as pymc3's own tutorial on LDA, in addition to the ...
user avatar
  • 2,302
2 votes
1 answer
426 views

What does each graph quadrant mean with LDAvis plot in R?

I write about the graph explained in this video that shows a big probability mass. It's a web-based interactive visualization of topics estimated using Latent Dirichlet Allocation that is built using ...
user avatar
0 votes
0 answers
46 views

Topic modelling when the "documents" are not static and new tokens are generated regularly

This question is related to this one and this one. As background, I'm working with Magic: the Gathering decklist data; I'm trying to automatically classify decks into different archetypes based on the ...
user avatar
0 votes
1 answer
826 views

Score the documents based on similarity to corpus using latent Dirichlet allocation

I have a corpus and number of documents with me. I am trying to generate a similarity score between the corpus and each of the available documents using latent dirichlet allocation. The goal is to see ...
user avatar
  • 161