deps/kb_meme/meme-5.0.1/src/spamo.c
/**************************************************************************
 * Calculates the maximum value in a bin to be used in output histograms
 **************************************************************************/
Calculates the maximum value in a bin to be used in output histograms
Calculates the maximum value in a bin to be used in output histograms
int calculate_bin_max(LINKLST_T* sorted_secondary_motifs) {
  LINK_T *node;
  SECONDARY_MOTIF_T *smotif;
  int binmax; 
  binmax = 0;
  for (node = linklst_first(sorted_secondary_motifs); node != NULL; node = linklst_next(node)) {
    smotif = (SECONDARY_MOTIF_T*)linklst_get(node);
    if (smotif->max_in_one_bin > binmax) {
      binmax = smotif->max_in_one_bin;
    }
  }
  return binmax;
}
int calculate_bin_max ( LINKLST_T * sorted_secondary_motifs ) { LINK_T * node ; SECONDARY_MOTIF_T * smotif ; int binmax ; binmax = 0 ; for ( node = linklst_first ( sorted_secondary_motifs ) ; node != NULL ; node = linklst_next ( node ) ) { smotif = ( SECONDARY_MOTIF_T * ) linklst_get ( node ) ; if ( smotif -> max_in_one_bin > binmax ) { binmax = smotif -> max_in_one_bin ; } } return binmax ; }
Calculates the maximum value in a bin to be used in output histograms
Calculates the maximum value in a bin to be used in output histograms
//calculate the maximum histogram count