src/main/java/eu/digitisation/output/CharStatTable.java
public double cer() {
        int spu = 0;
        int sub = 0;
        int add = 0;
        int tot = 0;

        for (Character c : leftKeySet()) {
            spu += value(c, EdOp.INSERT);
            sub += value(c, EdOp.SUBSTITUTE);
            add += value(c, EdOp.DELETE);
            tot += value(c, EdOp.KEEP) 
                    + value(c, EdOp.SUBSTITUTE)
                    + value(c, EdOp.DELETE);
        }
        
        return (spu + sub + add) / (double) tot;
    }
/**
 * Extract CER from character statistics
 * @return the global CER   
 */
Extract CER from character statistics
@return the global CER
Extract CER from character statistics @return the global CER
public double cer() {
        int spu = 0;
        int sub = 0;
        int add = 0;
        int tot = 0;
        for (Character c : leftKeySet()) {
            spu += value(c, EdOp.INSERT);
            sub += value(c, EdOp.SUBSTITUTE);
            add += value(c, EdOp.DELETE);
            tot += value(c, EdOp.KEEP) 
                    + value(c, EdOp.SUBSTITUTE)
                    + value(c, EdOp.DELETE);
        }
        return (spu + sub + add) / (double) tot;
    }
public double cer ( ) { int spu = 0 ; int sub = 0 ; int add = 0 ; int tot = 0 ; for ( Character c : leftKeySet ( ) ) { spu += value ( c , EdOp . INSERT ) ; sub += value ( c , EdOp . SUBSTITUTE ) ; add += value ( c , EdOp . DELETE ) ; tot += value ( c , EdOp . KEEP ) + value ( c , EdOp . SUBSTITUTE ) + value ( c , EdOp . DELETE ) ; } return ( spu + sub + add ) / ( double ) tot ; }
Extract CER from character statistics
 @return the global CER
Extract CER from character statistics @return the global CER