# Need help with Feature Engineering

I'm new to data science, and am working on projects to develop my skills. I'm currently working on the Loan Prediction practice competition offered by Analytics Vidhya.The goal is to build a predictive model that will determine whether a loan will be approved or not.

So far, my models (logistic regression, random forest) do not perform any better than simply using the applicant's credit history as a predictor.

I've read through the provided tutorial (I don't have high enough rep to include all the links): https://www.analyticsvidhya.com/blog/2016/01/complete-tutorial-learn-data-science-python-scratch-2/ which details the same results. The tutorial mentions that feature engineering will be important for this (and most) projects. I've found a few other resources for feature engineering ( http://data-informed.com/how-to-improve-machine-learning-tricks-and-tips-for-feature-engineering/ and http://adataanalyst.com/machine-learning/comprehensive-guide-feature-engineering/ ) being the most helpful) but I'm still unable to build a model with higher accuracy.

The variables included in the data set are:

Variable          Description
-------------     -----------------
Loan_ID           Unique Loan ID
Gender            Male/ Female
Married           Applicant married (Y/N)
Dependents        Number of dependents
Self_Employed     Self employed (Y/N)
ApplicantIncome   Applicant income
CoapplicantIncome Coapplicant income
LoanAmount        Loan amount in thousands
Loan_Amount_Term  Term of loan in months
Credit_History    credit history meets guidelines
Property_Area     Urban/Semi Urban/Rural
Loan_Status       Loan approved (Y/N)


I've first multiplied LoanAmount by 1000, to have the value in dollars.

I've tried creating the following new features:

TotalIncome = ApplicantIncome + CoapplicantIncome

Monthly_Payment = LoanAmount / Loan_Amount_Term

Payment_Ratio = Monthly_Payment / TotalIncome

household_size = the number of people in the household, derived from marital status and number of dependents

I also found that many of the continuous variables (LoanAmount, TotalIncome, Payment_Ratio) are right-skewed and have transformed them by taking the log.

None of these changes have had any effect. It seems that no matter what variables I include in my model, it will not achieve better accuracy than the model that only considers Credit_History.

Are there any obvious features I've overlooked?

What should I try next?

• Did you try interactions? – kjetil b halvorsen May 19 '17 at 18:08
• No. I'll look at that and update my question. – Richard Kublik May 19 '17 at 18:10

Why I am getting different predictions for manual polynomial expansion and using the R poly function?