abbreviate

0th

Percentile

Abbreviate function for item labels in transactions, itemMatrix and associations

Provides the generic function and the methods to abbreviate long item labels in transactions, associations (rules and itemsets) and transaction ID lists. Note that abbreviate is not a generic and this arules defines a generic with the R's abbreviate as the default.

Keywords
manip
Usage
abbreviate(names.arg, ...)
# S4 method for itemMatrix
abbreviate(names.arg, minlength = 4, ..., method = "both.sides")
# S4 method for rules
abbreviate(names.arg, minlength = 4, ..., method = "both.sides")
# S4 method for itemsets
abbreviate(names.arg, minlength = 4, ..., method = "both.sides")
# S4 method for transactions
abbreviate(names.arg, minlength = 4, ..., method = "both.sides")
# S4 method for tidLists
abbreviate(names.arg, minlength = 4, ..., method = "both.sides")
Arguments
names.arg

an object of class "transactions", "itemMatrix", "itemsets", "rules" or "tidLists".

minlength

number of characters allowed in abbreviation

method

apply to level and value (both.sides)

further arguments passed on to the default abbreviation function.

See Also

abbreviate in base.

Aliases
  • abbreviate
  • abbreviate,transactions-method
  • abbreviate,rules-method
  • abbreviate,itemsets-method
  • abbreviate,itemMatrix-method
  • abbreviate,tidLists-method
Examples
# NOT RUN {
data(Adult)
inspect(head(Adult, 1))

Adult_abbr <- abbreviate(Adult, 15)
inspect(head(Adult_abbr, 1))
# }
Documentation reproduced from package arules, version 1.5-4, License: GPL-3

Community examples

Looks like there are no examples yet.