powered by
For the gap between the predicted value and expected value of the model, the model validates the function
CVfunction(pred, actual)
Vector-value after model accuracy verification
: Value predicted by the model
: The real value
test.pred <- c(2,4,5,7,2,4) test.obs <- c(1,2,3,4,5,6) myres <- CVfunction(test.pred,test.obs) print(myres)
Run the code above in your browser using DataLab