MillerUpdatingRegression implements UpdatingMultipleLinearRegression { public boolean hasIntercept() { return this.hasIntercept; } @SuppressWarnings("unused") private  MillerUpdatingRegression();  MillerUpdatingRegression(int numberOfVariables, boolean includeConstant, double errorTolerance);  MillerUpdatingRegression(int numberOfVariables, boolean includeConstant); boolean hasIntercept(); long getN(); void addObservation(final double[] x, final double y); void addObservations(double[][] x, double[] y); void clear(); double[] getPartialCorrelations(int in); double getDiagonalOfHatMatrix(double[] row_data); int[] getOrderOfRegressors(); RegressionResults regress(); RegressionResults regress(int numberOfRegressors); RegressionResults regress(int[] variablesToInclude);  }
@Test public void testHasIntercept() { MillerUpdatingRegression instance = new MillerUpdatingRegression(10, false); if (instance.hasIntercept()) { Assert.fail("Should not have intercept"); } instance = new MillerUpdatingRegression(10, true); if (!instance.hasIntercept()) { Assert.fail("Should have intercept"); } }