Question: Load the data frame into memory with data(BreastCancer) in R studio. Notice in the summary() of glm0 that most of the levels of Cell.size and

Load the data frame into memory with data(BreastCancer) in R studio. Notice in the summary() of glm0 that most of the levels of Cell.size and Cell.shape became predictors and that they had very low p-values. It might be better to just have 2 levels for each variable. In this step, add two new columns to BreastCancer as listed below. Run summary() on Cell.size and Cell.shape as well as the new columns. Do you think what we did is a good idea? Why or why not?

i. Cell.small which is a binary factor that is 1 if Cell.size==1 and 0 otherwise

ii. Cell.regular which is a binary factor that is 1 if Cell.shape==1 and 0 otherwise

Create conditional density plots using the original Cell.size and Cell.shape. First attach() the data to reduce typing. Then use par(mfrow=c(1,2)) to set up a 1x2 grid for two cdplot() graphs with Class~Cell.size and Class~Cell.shape. Observing the plots, write a sentence or two comparing size and malignant, and shape and malignant. Do you think our cutoff points for size==1 and shape==1 were justified now that you see this graph? Why or why not?

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 Databases Questions!