【问题标题】:Plotting frequent itemsets and support绘制频繁项集和支持
【发布时间】:2019-09-04 12:26:17
【问题描述】:

我想创建一个图,比较根据最小支持度的变化值获得的频繁项集的数量。该怎么做?

ecParam1  = new("ECparameter", "confidence" = 0.8, "support" = 0.2) 
ecParam2  = new("ECparameter", "confidence" = 0.8, "support" = 0.3) 
ecParam3  = new("ECparameter", "confidence" = 0.8, "support" = 0.4) 

# Discovery of frequent itemsets
fsets1 <- eclat(Mushroom,ecParam1)
fsets2 <- eclat(Mushroom,ecParam2)
fsets3 <- eclat(Mushroom,ecParam3)

# Display the number of found itemsets for each parameter
length(fsets1) # Output: 38961
length(fsets2) # Output: 25735
length(fsets3) # Output: 533

例如,在这里我得到了与0.20.30.4 的支持相关的三个值。

【问题讨论】:

  • new 应该做什么?你在s4工作吗?!如果是,ECParameter 应该做什么?你在使用任何软件包吗?还包括您想要获得什么样的情节的样本。

标签: r plot data-mining


【解决方案1】:

从中创建一个两个变量的数据框:x(支持)和 y(频繁项集的数量)。

然后绘制该数据框。

【讨论】:

    猜你喜欢
    • 2016-01-26
    • 2020-02-14
    • 2018-11-06
    • 1970-01-01
    • 2018-03-25
    • 2014-01-25
    • 1970-01-01
    • 2012-12-20
    • 2016-09-18
    相关资源
    最近更新 更多