前往小程序,Get更优阅读体验!
立即前往
首页
学习
活动
专区
工具
TVP
发布
社区首页 >专栏 >tf-idf weighting

tf-idf weighting

作者头像
ke1th
发布2019-05-29 00:10:25
4930
发布2019-05-29 00:10:25
举报

版权声明:本文为博主原创文章,转载请注明出处。 https://cloud.tencent.com/developer/article/1437731

水平有限,如有错误请指正!

tf-idf weighting

tf(term frequency)

a document or zone that mentions a query term more often has more to do with that query and therefore should receive a higher score

query term: a set of words

NN:document中term的总数

tt:document中term出现的次数

tft=tN

tf_t=\frac{t}{N}

idf(inverse document frequency)

NN: document的数量

dftdf_t:有多少documents 包含tt

idft=logNdft

idf_t=log\frac{N}{df_t}

从公式可以看出:

  • dftdf_t 越小,idftidf_t越大,表明tt对文档的区分性更大
  • 反之

tf-idf weighting

tf-idft,d=tft,d∗idft

\text{tf-idf}_{t,d}=tf_{t,d}* idf_t

参考:

tf

idf

tf-idf

本文参与 腾讯云自媒体分享计划,分享自作者个人站点/博客。
原始发表:2016年12月01日,如有侵权请联系 cloudcommunity@tencent.com 删除

本文分享自 作者个人站点/博客 前往查看

如有侵权,请联系 cloudcommunity@tencent.com 删除。

本文参与 腾讯云自媒体分享计划  ,欢迎热爱写作的你一起参与!

评论
登录后参与评论
0 条评论
热度
最新
推荐阅读
目录
  • tf-idf weighting
    • tf(term frequency)
      • idf(inverse document frequency)
        • tf-idf weighting
        领券
        问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档