Calculate metrics for clusters