Description Usage Arguments Value
Creates a customer-by-time matrix from an event log.
dc.BuildCBTFromElog(elog, statistic = "freq")
event log, which is a data frame with columns for customer ID ("cust"), date ("date"), and optionally other columns such as "sales". Each row represents an event, such as a transaction.. For the total spend and average spend matrices, the event log must have a "sales" column. If the dates are not formatted to be in the order year-month-day, the columns of the customer-by-time matrix may not be ordered chronologically if the "date" column does not consist of date objects (R will order them alphabetically). This will cause problems with other functions, so it is better to convert the date column to date objects before running this function.
either "freq", "reach", "total.spend", or "average.spend". This determines what type of customer-by-time matrix is returned.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.