I\'ve just started using R and I\'m not sure how to incorporate my dataset with the following sample code:
sample(x, size, replace = FALSE, prob = NULL)
Use caTools package in R sample code will be as follows:-
data split = sample.split(data$DependentcoloumnName, SplitRatio = 0.6) training_set = subset(data, split == TRUE) test_set = subset(data, split == FALSE)