Question: Develop a model for classifying a customer as a purchaser or nonpurchaser. a. Partition the data randomly into a training set (800 records), validation set
Develop a model for classifying a customer as a purchaser or nonpurchaser.
a. Partition the data randomly into a training set (800 records), validation set (700 records), and test set (500 records).
b. Run logistic regression with L2 penalty, using method LogisticRegressionCV, to select the best subset of variables, then use this model to classify the data into purchasers and nonpurchasers. Use only the training set for running the model. (Logistic regression is used because it yields an estimated “probability of purchase,” which is required later in the analysis.)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
