Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Invalid
-
None
-
None
-
None
Description
The getSignificance(), getRSquare() and getR() methods can return infinite values when they should return 0, 1 and 1 respectively if the sum of squared errors is exactly 0.
From Jenkins test run:
java.lang.AssertionError: expected:<0.0> but was:<Infinity> at org.junit.Assert.fail(Assert.java:88) at org.junit.Assert.failNotEquals(Assert.java:743) at org.junit.Assert.assertEquals(Assert.java:494) at org.junit.Assert.assertEquals(Assert.java:592) at org.apache.commons.math3.stat.regression.SimpleRegressionTest.testPerfect(SimpleRegressionTest.java:546)