@Test public void testBreastCancer() { System.out.println("Breast Cancer"); MathEx.setSeed(19650218); int[] prediction = CrossValidation.classification(10, BreastCancer.x, BreastCancer.y, (x, y) -> QDA.fit(x, y)); int error = Error.of(BreastCancer.y, prediction); System.out.println("Error = " + error); assertEquals(24, error); }
public static QDA fit(Formula formula, DataFrame data) { return fit(formula, data, new Properties()); }
QDA implements SoftClassifier<double[]> { public static QDA fit(Formula formula, DataFrame data) { return fit(formula, data, new Properties()); } }
QDA implements SoftClassifier<double[]> { public static QDA fit(Formula formula, DataFrame data) { return fit(formula, data, new Properties()); } QDA(double[] priori, double[][] mu, double[][] eigen, Matrix[] scaling);  QDA(double[] priori, double[][] mu, double[][] eigen, Matrix[] scaling, IntSet labels); }
QDA implements SoftClassifier<double[]> { public static QDA fit(Formula formula, DataFrame data) { return fit(formula, data, new Properties()); } QDA(double[] priori, double[][] mu, double[][] eigen, Matrix[] scaling);  QDA(double[] priori, double[][] mu, double[][] eigen, Matrix[] scaling, IntSet labels); static QDA fit(Formula formula, DataFrame data); static QDA fit(Formula formula, DataFrame data, Properties prop); static QDA fit(double[][] x, int[] y); static QDA fit(double[][] x, int[] y, Properties prop); static QDA fit(double[][] x, int[] y, double[] priori, double tol); double[] priori(); @Override int predict(double[] x); @Override int predict(double[] x, double[] posteriori); }
QDA implements SoftClassifier<double[]> { public static QDA fit(Formula formula, DataFrame data) { return fit(formula, data, new Properties()); } QDA(double[] priori, double[][] mu, double[][] eigen, Matrix[] scaling);  QDA(double[] priori, double[][] mu, double[][] eigen, Matrix[] scaling, IntSet labels); static QDA fit(Formula formula, DataFrame data); static QDA fit(Formula formula, DataFrame data, Properties prop); static QDA fit(double[][] x, int[] y); static QDA fit(double[][] x, int[] y, Properties prop); static QDA fit(double[][] x, int[] y, double[] priori, double tol); double[] priori(); @Override int predict(double[] x); @Override int predict(double[] x, double[] posteriori);  }