question: protected double variance ( double [ ] s , double [ ] sS , double [ ] sumOfWeights ) { double var = 0 ; for ( int i = 0 ; i < s . length ; i ++ ) { if ( sumOfWeights [ i ] > 0 ) { var += singleVariance ( s [ i ] , sS [ i ] , sumOfWeights [ i ] ) ; } } return var ; }
target:  Computes variance for subsets.