摘要: 布朗语料库中使用条件概率分布函数ConditionalFreqDist,可以查看每个单词在各新闻语料中出现的次数。这在微博情感分析中非常有用,比如判断feature vector中代表positive or negative or neutral的各feature在每条tweet中出现的次数高低来判断该tweet的情感极性。from nltk.corpus import browncfd=nltk.ConditionalFreqDist((genre,word)for genre in brown.categories()for word in brown.words(categories=g 阅读全文
posted @ 2013-10-03 20:23 Charleston 阅读(3203) 评论(0) 推荐(0) 编辑