Exemple #1
0
 /**
  * Adds new point p to this histogram.
  *
  * @param p
  */
 public void update(double p) {
   update(p, 1);
 }
Exemple #2
0
  /**
   * Merges given histogram with this histogram.
   *
   * @param other histogram to merge
   */
  public void merge(StreamingHistogram other) {
    if (other == null) return;

    for (Map.Entry<Double, Long> entry : other.getAsMap().entrySet())
      update(entry.getKey(), entry.getValue());
  }