August 2017
Intermediate to advanced
288 pages
8h 6m
English
The data is imported using a standard function from R, as shown in the following code.
# Loading input and test dataxFeatures = c("Temperature", "Humidity", "Light", "CO2", "HumidityRatio")yFeatures = "Occupancy"occupancy_train <-as.matrix(read.csv("datatraining.txt",stringsAsFactors = T))occupancy_test <- as.matrix(read.csv("datatest.txt",stringsAsFactors = T))# subset features for modeling and transform to numeric valuesoccupancy_train<-apply(occupancy_train[, c(xFeatures, yFeatures)], ...