Skip to content

Instantly share code, notes, and snippets.

@Nithilaa
Last active July 26, 2021 07:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Nithilaa/982680df2510c3cc4c5f05ac33dba2f8 to your computer and use it in GitHub Desktop.
Save Nithilaa/982680df2510c3cc4c5f05ac33dba2f8 to your computer and use it in GitHub Desktop.
return a data frame wherein I’ll have the count of that particular vectorizer that’s applied to a given word and the columns would be my overall feature names that are the individual words.
features_df = pd.DataFrame(features.toarray(), columns=tf_vectorizer.get_feature_names())
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment