## Create transaction data set.
data <- list(
c("a", "b", "c"),
c("a", "b"),
c("a", "b", "d"),
c("b", "e"),
c("b", "c", "e"),
c("a", "d", "e"),
c("a", "c"),
c("a", "b", "d"),
c("c", "e"),
c("a", "b", "d", "e")
)
data <- as(data, "transactions")
data
## convert transactions to transaction ID lists
tl <- as(data, "tidLists")
tl
inspect(tl)
dim(tl)
dimnames(tl)
## inspect visually
image(tl)
## mine itemsets with transaction ID lists
f <- eclat(data, parameter = list(support = 0, tidLists = TRUE))
tl2 <- tidLists(f)
inspect(tl2)
Run the code above in your browser using DataLab