Skip to content

Commit

Permalink
Update javadocs
Browse files Browse the repository at this point in the history
  • Loading branch information
Lee Rhodes committed Feb 3, 2016
1 parent a6eaded commit 42e3224
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ private HeapQuantilesSketch(int k, short seed) {
* Obtains an instance of a QuantileSketch of double elements.
*
* @param k Parameter that controls space usage of sketch and accuracy of estimates.
* Must be greater than one and less than 65536.
* Must be greater than 0 and less than 65536.
* It is recommended that <i>k</i> be a power of 2 to enable merging of sketches with
* different values of <i>k</i>.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ public QuantilesSketchBuilder() {

/**
* Sets the parameter <i>k</i> that determines the accuracy and size of the sketch
* @param k determines the accuracy and size of the sketch. <i>k</i> must be greater than 1 and
* @param k determines the accuracy and size of the sketch. <i>k</i> must be greater than 0 and
* less than 65536.
* It is recommended that <i>k</i> be a power of 2 to enable merging of sketches with
* different values of <i>k</i>.
Expand Down Expand Up @@ -115,7 +115,7 @@ public QuantilesSketch build() {
* Returns a QuantilesSketch with the current configuration of this Builder and the
* given parameter <i>k</i>.
* @param k determines the accuracy and size of the sketch.
* Must be greater than 1 and less than 65536.
* Must be greater than 0 and less than 65536.
* @return a QuantilesSketch
*/
public QuantilesSketch build(int k) {
Expand Down
1 change: 0 additions & 1 deletion src/main/java/com/yahoo/sketches/quantiles/Util.java
Original file line number Diff line number Diff line change
Expand Up @@ -405,7 +405,6 @@ static double getAdjustedEpsilon(int k) {
* @return the resulting epsilon
*/ //used only by getAdjustedEpsilon()
private static double getTheoreticalEpsilon(int k, double ff) {
//TODO return something if k == 1 !!
if (k < 2) throw new IllegalArgumentException("K must be greater than one.");
// don't need to check in the other direction because an int is very small
double kf = k*ff;
Expand Down

0 comments on commit 42e3224

Please sign in to comment.