public double getMacroFMeasure ( ) { Map < String , Double > fMeasureForLabels = getFMeasureForLabels ( ) ; double totalFMeasure = 0 ; for ( Double d : fMeasureForLabels . values ( ) ) { totalFMeasure += d ; } return totalFMeasure / fMeasureForLabels . size ( ) ; }
Macro - averaged F - measure gives equal weight to each category regardless of its frequency . It is influenced more by the classifier performance on rare categories .