fix for secondary metric calculations