crossval function

k-fold cross-validation for the specified model