Average-case performance of the Apriori Algorithm

被引:16
|
作者
Purdom, PW [1 ]
Van Gucht, D
Groth, DP
机构
[1] Indiana Univ, Dept Comp Sci, Bloomington, IN 47405 USA
[2] Indiana Univ, Sch Informat, Bloomington, IN 47405 USA
关键词
data mining; algorithm analysis; Apriori Algorithm;
D O I
10.1137/S0097539703422881
中图分类号
TP301 [理论、方法];
学科分类号
081202 ;
摘要
The failure rate of the Apriori Algorithm is studied analytically for the case of random shoppers. The time needed by the Apriori Algorithm is determined by the number of item sets that are output (successes: item sets that occur in at least k baskets) and the number of item sets that are counted but not output (failures: item sets where all subsets of the item set occur in at least k baskets but the full set occurs in less than k baskets). The number of successes is a property of the data; no algorithm that is required to output each success can avoid doing work associated with the successes. The number of failures is a property of both the algorithm and the data. We find that under a wide range of conditions the performance of the Apriori Algorithm is almost as bad as is permitted under sophisticated worst-case analyses. In particular, there is usually a bad level with two properties: (1) it is the level where nearly all of the work is done, and (2) nearly all item sets counted are failures. Let l be the level with the most successes, and let the number of successes on level l be approximately ((m)(l)) for some m. Then, typically, the Apriori Algorithm has total output proportional to approximately ((m)(l)) and total work proportional to approximately ((m)(l+1)). In addition m is usually much larger than l, so the ratio of work to output is proportional to approximately m/(l+1). The analytical results for random shoppers are compared against measurements for three data sets. These data sets are more like the usual applications of the algorithm. In particular, the buying patterns of the various shoppers are highly correlated. For most thresholds, these data sets also have a bad level. Thus, under most conditions nearly all of the work done by the Apriori Algorithm consists in counting item sets that fail.
引用
收藏
页码:1223 / 1260
页数:38
相关论文
共 50 条