每次访问TDM时,R中的包tm返回'下标超出界限'

时间:2014-02-08 00:17:49

标签: r tm

我有1,500条推文的TDM:

> twdf_tdm
A term-document matrix (625 terms, 1500 documents)

Non-/sparse entries: 15366/922134
Sparsity           : 98%
Maximal term length: 26 
Weighting          : term frequency (tf)

我试图从tm和tm.plugin.sentiment包中运行各种函数,但是得到'下标超出界限'错误。这种情况发生在语料库中,TDM基于......:

> score(twdf_corpus)
Error in slam:::`[.simple_triplet_matrix`(x, i, j, ...) : 
  Subscript out of bounds.

......和TDM本身......:

> polarity(twdf_tdm)
Error in slam:::`[.simple_triplet_matrix`(x, i, j, ...) : 
  Subscript out of bounds.

我怀疑参与其中,但我找不到任何解决方案。有什么建议?

0 个答案:

没有答案