Skip to content

Latest commit

History

5 Commits

Folders and files

NameName
Last commit message
Last commit date

Repository files navigation

ATTENTION!

This function has been eaten (here) by my R package trinalysis which has many useful methods for working with transaction data.


SampleTransactions

Single R function to generate random transaction data such that the simulated data has a (somewhat) realistic pattern of customer churn.

Sample use:

# Transactions from 100 customerstransactions<- sampletransactions(Ncusts=100)
# Transactions from 100 customers with a standard deviation of 100 transactions per customertransactions<- sampletransactions(Ncusts=100, sd.transactions=100)
# Transactions from 100 customers with a standard deviation of $100 per transactiontransactions<- sampletransactions(Ncusts=100, sd.amount=100)
# Transactions between 1/1/2015 and 12/31/2015transactions<- sampletransactions(Ncusts=100, minDate=as.Date("2015-1-1"), maxDate=as.Date("2015-12-31"))
# Transactions falling into one of three categoriestransactions<- sampletransactions(Ncusts=100, products=c("A", "B", "D"))

About

No description, website, or topics provided.

Resources

Stars

3 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages