protected double negativeLogLikelihood(double[][] dataYs,double[][] probs){
  double logLikelihood=0;
  for (int i=0; i < dataYs.length; i++) {
    for (int j=0; j < m_numClasses; j++) {
      if (dataYs[i][j] == 1.0) {
        logLikelihood-=Math.log(probs[i][j]);
      }
    }
  }
  return logLikelihood;
}

protected double negativeLogLikelihood ( double [ ] [ ] dataYs , double [ ] [ ] probs ) { double logLikelihood = 0 ; for ( int i = 0 ; i < dataYs . length ; i ++ ) { for ( int j = 0 ; j < m_numClasses ; j ++ ) { if ( dataYs [ i ] [ j ] == 1.0 ) { logLikelihood -= Math . log ( probs [ i ] [ j ] ) ; } } } return logLikelihood ; }
returns the negative loglikelihood of the y - values ( actual class probabilities ) given the p - values ( current probability estimates ) .
