public double getNoiseSeparability ( ) { if ( noise . isEmpty ( ) ) return 1 ; double connectivity = 0 ; for ( int p : noise ) { CMMPoint npoint = cmmpoints . get ( p ) ; double maxConnection = 0 ; //TODO: some kind of pruning possible. what about weighting? for ( int c = 0 ; c < gt0Clusters . size ( ) ; c ++ ) { double connection = getConnectionValue ( npoint , c ) ; if ( connection > maxConnection ) maxConnection = connection ; } connectivity += maxConnection ; npoint . p . setMeasureValue ( "MaxConnection" , maxConnection ) ; } return 1 - ( connectivity / noise . size ( ) ) ; }
Calculates how well noise is separable from the given clusters Small values indicate bad separability values close to 1 indicate good separability