Learn R Programming

RemixAutoML (version 0.11.0)

AutoMarketBasketModel: AutoMarketBasketModel function runs a market basket analysis automatically

Description

AutoMarketBasketModel function runs a market basket analysis automatically. It will convert your data, run the algorithm, and add on additional significance values not orginally contained within.

Usage

AutoMarketBasketModel(data, OrderIDColumnName, ItemIDColumnName,
  LHS_Delimeter = ",", Support = 0.001, Confidence = 0.1,
  MaxLength = 2, MinLength = 2, MaxTime = 5)

Arguments

data

This is your transactions data set

OrderIDColumnName

Supply your column name for the Order ID Values

ItemIDColumnName

Supply your column name for the Item ID Values

LHS_Delimeter

Default delimeter for separating multiple ItemID's is a comma.

Support

Threshold for inclusion using support

Confidence

Threshold for inclusion using confidence

MaxLength

Maximum combinations of Item ID (number of items in basket to consider)

MinLength

Minimum length of combinations of ItemID (number of items in basket to consider)

MaxTime

Max run time per iteration (default is 5 seconds)

See Also

Chi-sq statistics and p-values based on this paper: http://www.cs.bc.edu/~alvarez/ChiSquare/chi2tr.pdf

Other Marketing Modeling: AutoRecomDataCreate, AutoRecommenderScoring, AutoRecommender

Examples

Run this code
# NOT RUN {
rules_data <- AutoMarketBasketModel(
  data,
  OrderIDColumnName = "OrderNumber",
  ItemIDColumnName = "ItemNumber",
  LHS_Delimeter = ",",
  Support = 0.001,
  Confidence = 0.1,
  MaxLength = 2,
  MinLength = 2,
  MaxTime = 5)
# }

Run the code above in your browser using DataLab