subject

First let us create an even split of the data into train and test partitions using createDataPartition. The code with a missing line is given below: set. seed(2)
# line of code
test <- iris[test_index,]
train <- iris[-test_index,]

Which code should be used in place of # line of code above?

a. test_index <- createDataPartition(y, times=1,p=0.5)
b. test_index <- sample(2,length(y),replace=FALSE) c. test_index <- createDataPartition(y, times=1,p=0.5,list=FALSE)
d. test_index <- rep(1,length(y))

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 24.06.2019 02:10
Aspeed limit sign that says "night" indicates the legal speed between sunset and sunrise.
Answers: 2
question
Computers and Technology, 24.06.2019 13:50
What does code do? a creates a text box that says "solid black" b creates a black border of any width c creates a black border 1 pixel wide
Answers: 1
question
Computers and Technology, 24.06.2019 21:30
The hybrid uses 144 to 158 volt batteries.
Answers: 1
question
Computers and Technology, 24.06.2019 23:00
What is a current gdp and what is a real gdp?
Answers: 1
You know the right answer?
First let us create an even split of the data into train and test partitions using createDataPartiti...
Questions
question
English, 01.02.2020 19:42
question
Mathematics, 01.02.2020 19:42
question
History, 01.02.2020 19:42
Questions on the website: 13722367