Question: For this problem, you will be working with thethoracic surgery data setfrom the University of California Irvine machine learning repository. This dataset contains information on

For this problem, you will be working with thethoracic surgery data setfrom the University of California Irvine machine learning repository. This dataset contains information on life expectancy in lung cancer patients after surgery.

The underlyingthoracic surgery datais in ARFF format. This is a text-based format with information on each of the attributes. You can load this data using a package such asforeignor by cutting and pasting the data section into a CSV file.

https://archive.ics.uci.edu/ml/datasets/Thoracic+Surgery+Data#

Assignment Instructions:

Include all of your answers in a R Markdown report. An example can be foundherethat you can use as a guide.

a.Fit a binary logistic regression model to the data set that predicts whether or not the patient survived for one year (theRisk1Yvariable) after the surgery. Use the glm() function to perform the logistic regression. SeeGeneralized Linear Modelsfor an example. Include a summary using the summary() function in your results.

b.According to the summary, which variables had the greatest effect on the survival rate?

c.To compute the accuracy of your model, use the dataset to predict the outcome variable. The percent of correct predictions is the accuracy of your model. What is the accuracy of your model?

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Mathematics Questions!