Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- print()
- print("TF-IDF + IncrementalPCA")
- tfidf_vect = feature_extraction.text.TfidfVectorizer(stop_words=stoplist)
- tfidf_vect.fit(docs)
- features = tfidf_vect.get_feature_names()
- tfidf = tfidf_vect.transform(docs)
- tfidf_lsi = decomposition.IncrementalPCA(n_components=2)
- tfidf_lsi.fit(tfidf.toarray())
- print_topic_cloud(tfidf_lsi.components_,features, max_words)
Add Comment
Please, Sign In to add comment