我正在使用一些试图实现TF-IDF方法来搜索文档相似性的文档。有一次,我需要计算术语频率(TF)。我在这个版本中有两个顶点:Documento ---> DocWord
DocWord顶点有以下字段:int frequency double tf double idf
Documento有:int wordCount
如果字段为:frequency / Documento.word Count,我需要更新所有Doc Word
我正在尝试运行的查询是:
更新DocWord集= frequency / in(“Documento_docwords”)。字数[0];
但这失败了。
尝试:
update DocWord set tf = (frequence / in("Documento_docwords").wordCount[0])