Closed fstermann closed 1 year ago
Create the generic for predict.
Example code and output:
predict(model.xgb, newdata = data.frame(speed = 10)) #> [1] 23.76096 prediction <- predict(model.xgb, newdata = cars.data[c(1, 2, 3, 4), ]) prediction #> prediction truth #> 1: 5.710046 2 #> 2: 5.710046 10 #> 3: 12.451396 4 #> 4: 12.451396 22
7
Create the generic for predict.
Example code and output: