Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Use the Bank.csv in attachment. Try the following estimation models and use them to predict customer subscription (y in the table). You should print
Use the Bank.csv in attachment. Try the following estimation models and use them to predict customer subscription (y in the table). You should print the cross validation score and confusion matrix for each model. Report which model works best. Linear model Logit model Decision tree KNN SVM The description of the dataset is available at: http://archive.ics.uci.edu/ml/datasets/Bank+Marketing Notice that you need to pre-process the data. For example, you need to code "no" as 0 and "yes" as 1 in column "loan". Also pay attention "marital" column-it can take three values: single, married and divorced. Can you just code single as 0, married as 1 and divorced as 2? (Hint: you may find two functions in pandas to be helpful: replace() and get_dummies()) While it is up to you what variables you want to put in the model, you should at least include the following variables: Marital Education Default . Housing Loan Duration Campaign Pdays (the description is incorrect. If value of pdays is -1, it means client was not previously contacted.)
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started