0
$\begingroup$

Im really confused about how TF is calculated. I understand that TF = count of term x/ total # of terms

For example:

Doc1: This is an example
Doc2: This is another example

TF(this,doc1)= 1/4= 0.25

However, some resources in R and links like this, Consider TF as count of term x; for ex: TF(this,doc1)= 1 then multiply it by IDF.

Is that correct?

$\endgroup$
  • $\begingroup$ a look at the wikipedia article reveals that both are possible, with different ways to model the term frequency being available. The decision, which one to use, it depending on your application context en.wikipedia.org/wiki/Tf%E2%80%93idf#Term_frequency_2 $\endgroup$ – deemel Dec 12 '17 at 10:20
  • $\begingroup$ @Rickyfox , but is the recommended one to use is the TF which is the count of the term ? $\endgroup$ – sara Dec 13 '17 at 4:54
  • $\begingroup$ that's what I was taught in my information retrieval class back then,yes. $\endgroup$ – deemel Dec 13 '17 at 7:47

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.