I've cut the RC1. I can cancel if you find blockers with compatibility for
Math. However I do not think it is an issue.

The org.apache.commons.math4.legacy.stat.interval package is the only one
that was ported. The Math interval package only contains one interval: the
binomial proportional confidence interval with many implementations in
different classes. The port puts all these into a single enum with each
implementation an enum instance for a simpler API. Note that the Math
org.apache.commons.math4.legacy.stat.interval package is not used anywhere
within Math and IIUC could be deleted.

The other changes in Statistics 1.2 are to support a range of an array when
creating descriptive statistics. It is this functionality that is used in
Math to support the existing descriptive statistics API:

> cd commons-math-legacy
> git grep ofRange
src/main/java/org/apache/commons/math4/legacy/stat/StatUtils.java:
   return Sum.ofRange(values, begin, begin + length).getAsDouble();
src/main/java/org/apache/commons/math4/legacy/stat/StatUtils.java:
   return SumOfSquares.ofRange(values, begin, begin + length).getAsDouble();
src/main/java/org/apache/commons/math4/legacy/stat/StatUtils.java:
   return org.apache.commons.statistics.descriptive.Product.ofRange(values,
begin, begin + length)
src/main/java/org/apache/commons/math4/legacy/stat/StatUtils.java:
   return SumOfLogs.ofRange(values, begin, begin + length).getAsDouble();
src/main/java/org/apache/commons/math4/legacy/stat/StatUtils.java:
   return org.apache.commons.statistics.descriptive.Mean.ofRange(values,
begin, begin + length)
src/main/java/org/apache/commons/math4/legacy/stat/StatUtils.java:
   return GeometricMean.ofRange(values, begin, begin +
length).getAsDouble();
src/main/java/org/apache/commons/math4/legacy/stat/StatUtils.java:
   return
org.apache.commons.statistics.descriptive.Variance.ofRange(values, begin,
begin + length)
src/main/java/org/apache/commons/math4/legacy/stat/StatUtils.java:
   return
org.apache.commons.statistics.descriptive.Variance.ofRange(values, begin,
begin + length)
src/main/java/org/apache/commons/math4/legacy/stat/StatUtils.java:
   return Max.ofRange(values, begin, begin + length).getAsDouble();
src/main/java/org/apache/commons/math4/legacy/stat/StatUtils.java:
   return Min.ofRange(values, begin, begin + length).getAsDouble();
src/main/java/org/apache/commons/math4/legacy/stat/descriptive/Statistics.java:
           super(org.apache.commons.statistics.descriptive.Mean::ofRange);
src/main/java/org/apache/commons/math4/legacy/stat/descriptive/Statistics.java:

 super(org.apache.commons.statistics.descriptive.GeometricMean::ofRange);
src/main/java/org/apache/commons/math4/legacy/stat/descriptive/Statistics.java:

 super(org.apache.commons.statistics.descriptive.Kurtosis::ofRange);
src/main/java/org/apache/commons/math4/legacy/stat/descriptive/Statistics.java:
           super(org.apache.commons.statistics.descriptive.Max::ofRange);
src/main/java/org/apache/commons/math4/legacy/stat/descriptive/Statistics.java:
           super(org.apache.commons.statistics.descriptive.Min::ofRange);
src/main/java/org/apache/commons/math4/legacy/stat/descriptive/Statistics.java:

 super(org.apache.commons.statistics.descriptive.Skewness::ofRange);
src/main/java/org/apache/commons/math4/legacy/stat/descriptive/Statistics.java:

 super(org.apache.commons.statistics.descriptive.Variance::ofRange);
src/main/java/org/apache/commons/math4/legacy/stat/descriptive/Statistics.java:

 super(org.apache.commons.statistics.descriptive.SumOfSquares::ofRange);
src/main/java/org/apache/commons/math4/legacy/stat/descriptive/Statistics.java:
           super(org.apache.commons.statistics.descriptive.Sum::ofRange);
src/main/java/org/apache/commons/math4/legacy/stat/descriptive/moment/SemiVariance.java:
        double m =
org.apache.commons.statistics.descriptive.Mean.ofRange(values, start, start
+ length).getAsDouble();

Alex



On Fri, 12 Sept 2025 at 15:54, Gilles Sadowski <[email protected]> wrote:

> Hi.
>
> Le ven. 12 sept. 2025 à 16:05, Alex Herbert <[email protected]> a
> écrit :
> >
> > I would like to release v1.2 of Statistics. The new features added since
> > v1.1 are used in the latest Math snapshot and it would be good to remove
> > the snapshot dependency.
> >
> > Let me know if there is additional functionality to include, otherwise I
> > will prepare a release candidate.
>
> I've lost track of this; sorry if I'm missing something in the following
> remark.
> It seems that although [Math] depends on version 1.2-SNAPSHOT
> of [Statistics], its code was not thoroughly updated to use the new
> functionality provided by [Statistics].  I've only looked at package
>   org.apache.commons.math4.legacy.stat.interval
> vs
>   org.apache.commons.statistics.interval
>
> Wouldn't it be safer to clean up [Math] first so as to catch any
> missing feature worth having in the upcoming release (to ensure
> that all duplicate code can indeed be removed from [Math])?
>
> Regards,
> Gilles
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>

Reply via email to