Skip to content

Commit

Permalink
added max and min to StatCounter output, updated doc
Browse files Browse the repository at this point in the history
  • Loading branch information
dwmclary committed Mar 15, 2014
1 parent 1a97558 commit 21dd366
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions core/src/main/scala/org/apache/spark/util/StatCounter.scala
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ class StatCounter(values: TraversableOnce[Double]) extends Serializable {
private var n: Long = 0 // Running count of our values
private var mu: Double = 0 // Running mean of our values
private var m2: Double = 0 // Running variance numerator (sum of (x - mean)^2)
private var max_v: Double = Double(-Infinity) // Running max of our values
private var min_v: Double = Double(Infinity) // Running min of our values
private var max_v: Double = Double.PositiveInfinity // Running max of our values
private var min_v: Double = Double.NegativeInfinity // Running min of our values

merge(values)

Expand Down

0 comments on commit 21dd366

Please sign in to comment.