Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Question: Showing vocabularies weights #169

Open
juneMJ opened this issue Jun 13, 2022 · 2 comments
Open

Question: Showing vocabularies weights #169

juneMJ opened this issue Jun 13, 2022 · 2 comments
Labels
enhancement New feature or request

Comments

@juneMJ
Copy link

juneMJ commented Jun 13, 2022

Hello,
I'm very interested in your package and enjoying it a lot so far.
I wonder if there is a way to show the term weights of the topic vocabularies after modeling.
Also I noticed there is no TF.IDF term weighting measure, is there a possibility to add it to the term weighting schemes?
Thank you.

@bab2min bab2min added the enhancement New feature or request label Jun 15, 2022
@bab2min
Copy link
Owner

bab2min commented Jun 15, 2022

Hi @juneMJ
Thank you for your suggestion.
As you said, current version of tomotopy doesn't provide API for accessing weights value of each term of vocabularies or for adding custom term weighting schemes. I'll add it for the next update plan.

However, apart from this, I think you can just use IDF term weighting instead of TF.IDF. Because term weighting is applied every terms in each document, so if you have 10 term Xs in the document, IDF is applied to each term, and the sum of weights of term X in the document will be 10 * IDF(X). It is exactly equal to the result of tf-idf.
On the other hand, if you set the term weight of X is 10 * IDF(X) as following tf-idf, the sum of weights of term X in the document will be 10 * 10 * IDF(X).

@juneMJ
Copy link
Author

juneMJ commented Jun 15, 2022

@bab2min That would be cool, and I understand now your point about IDF. Thank you for your response!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants