calc_mean_perf function

Generic function to calculate mean performance curves for multiple models