TermFrequency computes cosine measure and recall