Note: You need to submit your answers in a word document. You need to transfer the results from the excel file into the word document. In addition, you must submit your Excel file (we prefer a single excel file with one or multiple worksheet for each question) but note that only the word document will be marked. If you think there is any issue or unclarity in any question, please make your assumptions (if there is any) and clearly explain them in your report.
You need to add the coversheet and sign it. Please write the name of your tutor as in the coversheet.
The analyses and the answers must be your own individual work without consultation of any other person. Also, you are not allowed to help/advise other students.
Open excel sheet which is called worksheet “Q1” of the Excel file (provided for this assignment) and develop the following visualizations: (3+3+3=9 marks).
A figure showing whether there is a relationship between age and income.
A figure showing distribution of income.
A figure illustrating registration date and frequency of people who are registered.
Excel worksheet “Q2” is related to a financial institute that provides loans to its customers. The intention from investigating the data is to identify the customer credibility. The description of variables are presented below: (5+6=11 marks)
Variable
Meaning
Credibility
1= good
2= bad
Credit amount
No description needed
Length of employment
1= less than 20 years
2= between 20 and 40 years
3= between 40 and 60 years
Sex and Marital Status
1= married made
2= married female
3= divorced male or female
Age
Age in years
Considering we want to develop a model and consider credibility as a dependent variable answer the following questions:
How many independent categorical and numerical variables exists in the data set?
If we want to develop a logistic regression model how many coefficients would we have excluding intercept.
The data presented in worksheet “Q3” is the results of a 4-year study conducted to assess how age, weight, and gender influence the risk of diabetes. Risk is interpreted as the probability (times 100) that the patient will have diabetes over the next 4-year period. What predictive model you suggest relating risk of diabetes to the person’s age, weight and the gender. Why? (5 marks)
There are 500 client records in the worksheet “Q4” of the Excel file (provided for this assignment) who have shopped many special products from an e-Business website. Each record includes data on types of product purchased (between 1-5), purchase amount ($), age, gender, family size of the customer, whether the client has a membership and whether the customer has a discount card. (8+7=15 marks)
Develop a multiple regression model to predict the spend amount based on other variables in the data set. Write the final equation and interpret the coefficients of the model and explain the accuracy of the model?
What would be your recommendation to improve the accuracy of this model? What is your recommendation to improve the simplicity of the model?
The following screenshot is taken from the logistics regression output from a data set which can be found here. The data set is about blood donation of a center. In this data set, there are four dependent variables and one independent variable. Independent variables are explained below. Dependent variable is if another donation happened in March 2007.
R
months since last donation
F
total number of donation)
M
total blood donated in
T
months since first donation
(8+7=15 marks)
Write the logistics regression equation based on the output?
In the Excel sheet “Q5” you can find the actual values of dependent variable versus the prediction values in the test set. Calculate overall error, sensitivity, and specificity. Explain the steps of calculations.
Consider the following confusion matrix as the result of a logistic regression model that aims to classify a dependent variable y (whether the patient is having heart attack or not) based on a given set of independent variables. In this model, y = 1 indicates having a heart attack and y = 0 indicates not having a heart attack. The cut-off value is considered as 50%. Do you think we need to make a change to the cut-off value? Justify your answer (5 marks)
Predicted class
01
Actual c
Leave a Reply