calc_perf_metrics function

Get performance metrics for test data