
library(data.table)

## Setup
.us()
.us()
setScience("Accounting", subl=FALSE, create=FALSE)
analytics()


# --------------------------- #
# --------------------------- #
##  ***       Whenever possible aim for    User-Conutry-Date    ***  ##
## it should be 'country' FIRST, then 'month'.  Since if a user travels abroad, that is not a change in plan. (They don't pay less/more. or do they?)
kCols_UCnD      <- c("userid", "country", "month")
kCols_UCnDL     <- c("userid", "country", "month", "lastStream_byUCnDPMb")

kCols_D         <- c("month")
# --------------------------- #
# --------------------------- #

# --------------------------- #
kCols_UCn      <- c("userid", "country")
kCols_UCnD     <- c("userid", "country", "month")
kCols_UCnDP    <- c("userid", "country", "month", "product")
kCols_UCnDPMb  <- c("userid", "country", "month", "product", "mobile")

kCols_UD       <- c("userid", "month")
kCols_UDP      <- c("userid", "month", "product")
# --------------------------- #

# --------------------------- #
#  COUNTRY -- DATE -- ....    #
# --------------------------- #
kCols_CnD      <- c("country", "month")
kCols_CnDP     <- c("country", "month", "product")
kCols_CnDPMb   <- c("country", "month", "product", "mobile")
kCols_CnDPU    <- c("country", "month", "product", "userid")
kCols_CnDUP    <- c("country", "month", "userid", "product") # same value, different order. For quicker counting
kCols_CnDU     <- c("country", "month", "userid")
kCols_CnDUPMb  <- c("country", "month", "userid", "product", "mobile")

kCols_PUCnD    <- c("product", "userid", "country", "month") # same value, different order. For quicker counting
# --------------------------- #

# --------------------------- #
#  DATE -- COUNTRY -- ....
# --------------------------- #
kCols_DCn      <- c("month", "country")
kCols_DCnP     <- c("month", "country", "product")
kCols_DCnPMb   <- c("month", "country", "product", "mobile")
kCols_DCnPU    <- c("month", "country", "product", "userid")
kCols_DCnUP    <- c("month", "country", "userid", "product") # same value, different order. For quicker counting
kCols_DCnU     <- c("month", "country", "userid")
kCols_DCnUPMb  <- c("month", "country", "userid", "product", "mobile")

kCols_DP       <- c("month", "product")
# --------------------------- #


