dominicksData | R Documentation |
The Dominicks Scanner data, provided by the University of Chicago Booth School of Business, contains around 5 years of product-level data from over 100 stores, collected from 1989-1994. The data consist of a UPC file that contains information on the products, and a movement file that contains the information on prices and sales. For a complete description of the data, see Dominicks data website and the Dominicks data user manual. This function downloads and merges the movement and UPC files, then merges the result with data detailing the dates of each of the weeks in the movement file.
dominicksData(x, movementcsv = NULL, UPCcsv = NULL)
x |
the name of the category to retrieve, see details for list. |
movementcsv |
the path to the movement csv file for one product category. The default is NULL, which downloads the file from the website. |
UPCcsv |
the path to the UPC csv file for one product category. The default is NULL, which downloads the file from the website. |
The following transformations are performed on the data:
The quantity variable is set to MOVE, which is the number of individual units sold
The price variable is set to PRICE/QTY, which is the unit price. This accounts for the fact that sometimes products are sold in bundles (e.g., two-for-one promotions).
expenditure is given by PRICE*MOVE/QTY.
All observations where the variable OK equals 0, or price is less than or equal to 0, are dropped.
If you have already downloaded the movement and UPC csv files for a category from the website, then you can pass the file paths of those files to the function and just have it combine them with the weeks dataset. The default is to download the files for you from the website.
The products available are:
Analgesics
Bath Soap
Beer
Bottled Juices
Cereals
Cheeses
Cigarettes
Cookies
Crackers
Canned Soup
Dish Detergent
Front-end-candies
Frozen Dinners
Frozen Entrees
Frozen Juices
Fabric Softeners
Grooming Products
Laundry Detergents
Oatmeal
Paper Towels
Refrigerated Juices (not currently available)
Soft Drinks
Shampoos
Snack Crackers
Soaps
Toothbrushes
Canned Tuna
Toothpastes
Bathroom Tissues
James M. Kilts Center, University of Chicago Booth School of Business
## Not run:
analgesics <- dominicksData("Analgesics")
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.