Provides the generic function `crossTable`

and the S4 method to
cross-tabulate joint occurrences across pairs of items.

1 2 3 4 | ```
crossTable(x, ...)
## S4 method for signature 'itemMatrix'
crossTable(x, measure = c("count", "support", "probability",
"lift", "chiSquared"), sort = FALSE)
``` |

`x` |
object to be cross-tabulated
( |

`measure` |
measure to return. Default is co-occurence counts. |

`sort` |
sort the items by support. |

`...` |
aditional arguments. |

A symmetric matrix of n time n, where n is the number of items times
in `x`

. The matrix contains the co-occurrence counts between pairs of
items.

Michael Hahsler

`transactions-class`

,
`itemMatrix-class`

.

1 2 3 4 5 6 7 8 9 10 11 12 13 | ```
data("Groceries")
ct <- crossTable(Groceries, sort=TRUE)
ct[1:5, 1:5]
sp <- crossTable(Groceries, measure="support", sort=TRUE)
sp[1:5,1:5]
lift <- crossTable(Groceries, measure="lift", sort=TRUE)
lift[1:5,1:5]
chi2 <- crossTable(Groceries, measure="chiSquared", sort=TRUE)
chi2[1:5,1:5]
``` |

Questions? Problems? Suggestions? Tweet to @rdrrHQ or email at ian@mutexlabs.com.

All documentation is copyright its authors; we didn't write any of that.