Class QuantilesFloatsAPI.FloatsPartitionBoundaries

  • Enclosing interface:
    QuantilesFloatsAPI

    public static class QuantilesFloatsAPI.FloatsPartitionBoundaries
    extends Object
    This encapsulates the essential information needed to construct actual partitions and is returned from the getPartitionBoundaries(int, QuantileSearchCritera) method.
    • Field Detail

      • N

        public long N
        The total number of items presented to the sketch.

        To compute the weight or density of a specific partition i where i varies from 1 to m partitions:

        
         long N = getN();
         double[] ranks = getRanks();
         long weight = Math.round((ranks[i] - ranks[i - 1]) * N);
         
      • ranks

        public double[] ranks
        The normalized ranks that correspond to the returned boundaries. The returned array is of size (m + 1), where m is the requested number of partitions. Index 0 of the returned array is always 0.0, and index m is always 1.0.
      • boundaries

        public float[] boundaries
        The partition boundaries as quantiles. The returned array is of size (m + 1), where m is the requested number of partitions. Index 0 of the returned array is always getMinItem(), and index m is always getMaxItem().
    • Constructor Detail

      • FloatsPartitionBoundaries

        public FloatsPartitionBoundaries()