OJ.Rd
The data contains 1070 purchases where the customer either purchased Citrus Hill or Minute Maid Orange Juice. A number of characteristics of the customer and product are recorded.
OJ
A data frame with 1070 observations on the following 18 variables.
Purchase
A factor with levels CH
and MM
indicating whether the customer purchased Citrus Hill or Minute
Maid Orange Juice
WeekofPurchase
Week of purchase
StoreID
Store ID
PriceCH
Price charged for CH
PriceMM
Price charged for MM
DiscCH
Discount offered for CH
DiscMM
Discount offered for MM
SpecialCH
Indicator of special on CH
SpecialMM
Indicator of special on MM
LoyalCH
Customer brand loyalty for CH
SalePriceMM
Sale price for MM
SalePriceCH
Sale price for CH
PriceDiff
Sale price of MM less sale price of CH
Store7
A factor with levels No
and Yes
indicating whether the sale is at Store 7
PctDiscMM
Percentage discount for MM
PctDiscCH
Percentage discount for CH
ListPriceDiff
List price of MM less list price of CH
STORE
Which of 5 possible stores the sale occured at
Stine, Robert A., Foster, Dean P., Waterman, Richard P. Business Analysis Using Regression (1998). Published by Springer.
James, G., Witten, D., Hastie, T., and Tibshirani, R. (2013) An Introduction to Statistical Learning with applications in R, www.StatLearning.com, Springer-Verlag, New York
summary(OJ)#> Purchase WeekofPurchase StoreID PriceCH PriceMM #> CH:653 Min. :227.0 Min. :1.00 Min. :1.690 Min. :1.690 #> MM:417 1st Qu.:240.0 1st Qu.:2.00 1st Qu.:1.790 1st Qu.:1.990 #> Median :257.0 Median :3.00 Median :1.860 Median :2.090 #> Mean :254.4 Mean :3.96 Mean :1.867 Mean :2.085 #> 3rd Qu.:268.0 3rd Qu.:7.00 3rd Qu.:1.990 3rd Qu.:2.180 #> Max. :278.0 Max. :7.00 Max. :2.090 Max. :2.290 #> DiscCH DiscMM SpecialCH SpecialMM #> Min. :0.00000 Min. :0.0000 Min. :0.0000 Min. :0.0000 #> 1st Qu.:0.00000 1st Qu.:0.0000 1st Qu.:0.0000 1st Qu.:0.0000 #> Median :0.00000 Median :0.0000 Median :0.0000 Median :0.0000 #> Mean :0.05186 Mean :0.1234 Mean :0.1477 Mean :0.1617 #> 3rd Qu.:0.00000 3rd Qu.:0.2300 3rd Qu.:0.0000 3rd Qu.:0.0000 #> Max. :0.50000 Max. :0.8000 Max. :1.0000 Max. :1.0000 #> LoyalCH SalePriceMM SalePriceCH PriceDiff Store7 #> Min. :0.000011 Min. :1.190 Min. :1.390 Min. :-0.6700 No :714 #> 1st Qu.:0.325257 1st Qu.:1.690 1st Qu.:1.750 1st Qu.: 0.0000 Yes:356 #> Median :0.600000 Median :2.090 Median :1.860 Median : 0.2300 #> Mean :0.565782 Mean :1.962 Mean :1.816 Mean : 0.1465 #> 3rd Qu.:0.850873 3rd Qu.:2.130 3rd Qu.:1.890 3rd Qu.: 0.3200 #> Max. :0.999947 Max. :2.290 Max. :2.090 Max. : 0.6400 #> PctDiscMM PctDiscCH ListPriceDiff STORE #> Min. :0.0000 Min. :0.00000 Min. :0.000 Min. :0.000 #> 1st Qu.:0.0000 1st Qu.:0.00000 1st Qu.:0.140 1st Qu.:0.000 #> Median :0.0000 Median :0.00000 Median :0.240 Median :2.000 #> Mean :0.0593 Mean :0.02731 Mean :0.218 Mean :1.631 #> 3rd Qu.:0.1127 3rd Qu.:0.00000 3rd Qu.:0.300 3rd Qu.:3.000 #> Max. :0.4020 Max. :0.25269 Max. :0.440 Max. :4.000