从R中的Clustree获取微集群的数量

时间:2016-05-10 15:53:35

标签: r moa

我无法从Clustree中检索出数量的微团簇。以下是代码:

library(streamMOA)
data <- read.csv("data.csv", sep = ",", header = TRUE)
stream <- DSD_Memory(data)
clustree <- DSC_ClusTree(maxHeight = 3)
reset_stream(stream)
update(clustree, stream, 200)

现在如果打印clustree对象,我得到:

print(clustree)

ClusTree
Class: DSC_ClusTree, DSC_Micro, DSC_MOA, DSC 
Number of micro-clusters: 20 

但是,clustree&amp; description,clustree $ options或clustree&amp; javaObj不会给出微集群的数量。有什么帮助吗?

1 个答案:

答案 0 :(得分:0)

a_greater_than_five&lt; - ifelse(a&gt; 5,TRUE,FALSE)