Answered step by step
Verified Expert Solution
Question
1 Approved Answer
We have the following dataframe in R: age
We have the following dataframe in R:
age<-c(67,54,49,50)
year_of_operation<-c(2011,2012,2010,2013)
No_Pos_aux<-c(3,0,1,2)
survival_status<-c(1,2,2,1)
df <- data.frame ( age,year_of_operation,No_Pos_aux,survival_status )
Do the following in R:
a. Create a dataframe consisting of only the last two columns.
b. Create a dataframe consisting of only the first and last row.
c. Create a dataframe called df2 where every entry in the No-Pos_aux and survival_status columns is 0
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started