modified the iterative script to repeat k times and compute the average acc with k equal to the fold