susanli2016 / NLP-with-Python

Scikit-Learn, NLTK, Spacy, Gensim, Textblob and more
2.72k stars 2.01k forks source link

About code #15

Open psammy007 opened 4 years ago

psammy007 commented 4 years ago

for idx, topic in lda_model_tfidf.print_topics(-1): print('Topic: {} Word: {}'.format(idx, topic)) whats the significance of -1 in first line...

smth-27 commented 10 months ago

'print_topics(-1)' prints the top words for all topics in the LDA model.