JasonKessler / scattertext

Beautiful visualizations of how language differs among document types.
Apache License 2.0
2.23k stars 287 forks source link

Is there a way to store the top scored documents in a seperate dataframe for each category? #75

Closed Alisha1992 closed 3 years ago

Alisha1992 commented 3 years ago

image

Hi Jason,

Could you please let me know if there is a way to store the documents generated for each word in the category as of now in this current package?? Please reply ASAP.

Is there is any particular method name to get the documents for each word in the category??

Your help would be appreciated.

Thanks, Alisha Panda

JasonKessler commented 3 years ago

You can run the search(str) function on a ParsedCorpus instance (built by CorpusFromParsedDocuments) to get a data frame with all matching documents.

If you'd like the exact text returned in the UI, you'll have to modify the Javascript code.