commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gilles <>
Subject [Math] "KolmogorovSmirnovTest" cleanup
Date Fri, 11 Mar 2016 13:40:40 GMT

There are deprecated fields and constructor in the 
class (in package "o.a.c.m.stat.inference"):

  * protected static final int SMALL_SAMPLE_PRODUCT
  * protected static final int MONTE_CARLO_ITERATIONS
  * public KolmogorovSmirnovTest(RandomGenerator rng)

In particular the Javadoc for the latter indicates:
"The #monteCarloP(double, int, int, boolean, int) that uses the 
supplied to this constructor is deprecated as of version 3.6."

But the public method "monteCarloP" is _not_ annotated as deprecated, 
neither is the field

  * private final RandomGenerator rng

although its Javadoc says:
"Random data generator used by {@link #monteCarloP(double, int, int, 
boolean, int)}"

I found this related issue still open in JIRA:

Thus, can we effectively delete the "monteCarloP" method and all the 
methods which it calls?
Should I open a specific issue for this action, or can I use MATH-1179 

Alternatively, isn't the Monte-Carlo option a feature worth keeping?
If there are several ways to obtain a result, shouldn't we implement 
in separate classes (cf. "Strategy" pattern advertized in CM's 
document)? [That would certainly help cleaning up to have smaller bits 
code: "KolmogorovSmirnovTest" is 1200+ lines long.]


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message