Posted: June 6th, 2021

Data Science Logistic Regression

Save Time On Research and Writing
Hire a Pro to Write You a 100% Plagiarism-Free Paper.
Get My Paper

 
Objective: Using Logistic Regression to handle a binary outcome.
 Given the prostate cancer dataset, in which biopsy results are given for 97 men: • 
You are to predict tumor spread in this dataset of 97 men who had undergone a biopsy. • 
The measures to be used for prediction are: age, lbph, lcp, gleason, and lpsa. 
This implies that binary dependent variable of lcavol will be the outcome variable. 
We start by loading the appropriate libraries in R: ROCR, ggplot2, and aod packages as follows: 
> install.packages(“ROCR”) 
> install.packages(“ggplot2”)
 > install.packages(“aod”) 
> library(ROCR) 
> library(ggplot2)
 > library(aod)
 Next, we load the csv file and check the statistical properties of the csv File as follow: 
> setwd(“C:/RData”) # your working directory > tumor <- read.csv(“prostate.csv”) # loading the file > str(tumor)
 # check the properties of the file . . . continue from here! 
Reference R Documentation (2016). Prostate cancer data. Retrieved from http://rafalab.github.io/pages/649/prostate.html

Expert paper writers are just a few clicks away

Place an order in 3 easy steps. Takes less than 5 mins.

Calculate the price of your order

You will get a personal manager and a discount.
We'll send you the first draft for approval by at
Total price:
$0.00