Inheritance: Accord.Statistics.Kernels.KernelBase, IKernel
Exemple #1
0
        public void FunctionTest2()
        {
            int s = 2;
            int p = 1;
            Anova target = new Anova(s, p);

            double[] x = new double[] { 5, 4 };
            double[] y = new double[] { 3, 2 };

            double expected = 23;
            double actual = target.Function(x, y);
            Assert.AreEqual(expected, actual);
        }
Exemple #2
0
        public void FunctionTest()
        {
            int s = 2;
            int p = 2;
            Anova target = new Anova(s, p);

            // Values from examples by Manju M. Pai, 2003
            // The code, however, is computed differently.

            double[] x = new double[] { 5, 4 };
            double[] y = new double[] { 3, 2 };

            double expected = 120;
            double actual = target.Function(x, y);
            Assert.AreEqual(expected, actual);
        }
Exemple #3
0
        public void FunctionTest3()
        {
            int s = 5;
            int p = 3;
            Anova target = new Anova(s, p);

            double[] x = new double[] { 5, 4, 3, 1, 1 };
            double[] y = new double[] { 3, 2, 5, 4, 1 };

            double expected = 4277;
            double actual = target.Function(x, y);
            Assert.AreEqual(expected, actual);
        }