perf_cv function

Cross Validation