Examples of evaluate()


Examples of org.apache.commons.math.stat.descriptive.moment.StandardDeviation.evaluate()

     
    });
    vra.searchSolutions();
   
    StandardDeviation dev = new StandardDeviation();
    double standardDeviation = dev.evaluate(results);
    double initialThreshold = standardDeviation / 2;
   
    schrimpfAcceptance.setInitialThreshold(initialThreshold);
   
    logger.info("warmup done");

Examples of org.apache.commons.math.stat.descriptive.moment.Variance.evaluate()

            for (int j = 0; j < i; j++) {
              double cov = covariance(matrix.getColumn(i), matrix.getColumn(j), biasCorrected);
              outMatrix.setEntry(i, j, cov);
              outMatrix.setEntry(j, i, cov);
            }
            outMatrix.setEntry(i, i, variance.evaluate(matrix.getColumn(i)));
        }
        return outMatrix;
    }

    /**
 

Examples of org.apache.commons.math.stat.descriptive.rank.Median.evaluate()

  }
 
  public static Double median(double[] values)
  {
    Median medianCalculator = new Median();
    return medianCalculator.evaluate(values);
  }
 
  public static Double median(Collection<Double> values)
  {
    double[] v = new double[values.size()];

Examples of org.apache.commons.math.stat.descriptive.rank.Min.evaluate()

      final double bondPriceForward = METHOD_BOND_SEC.dirtyPriceFromCurves(BOND_FUTURE.getDeliveryBasket()[loopbasket], ISSUER_MULTICURVES);
      netBasisExpected[loopbasket] = bondPriceForward - (priceFuture * CONVERSION_FACTOR[loopbasket] + BOND_FUTURE.getDeliveryBasket()[loopbasket].getAccruedInterest());
      assertEquals("Bond future security Discounting Method: netBasis", netBasisExpected[loopbasket], netBasisComputed[loopbasket], 1.0E-10);
    }
    final Min minFunction = new Min();
    final double netBasisMin = minFunction.evaluate(netBasisComputed);
    final double priceFutureFromNetBasis = METHOD_FUT_SEC_DSC.priceFromNetBasis(BOND_FUTURE, ISSUER_MULTICURVES, netBasisMin);
    assertEquals("Bond future security Discounting Method: netBasis", priceFuture, priceFutureFromNetBasis, 1.0E-10);
  }

  @Test

Examples of org.apache.commons.math.stat.descriptive.rank.Percentile.evaluate()

      DescriptiveStatistics descriptiveStatistics = new DescriptiveStatistics(weightedValues);
      String unit = Iterables.getOnlyElement(units);
      stdout.printf(
          "  %s%s: min=%.2f, 1st qu.=%.2f, median=%.2f, mean=%.2f, 3rd qu.=%.2f, max=%.2f%n",
          entry.getKey(), unit.isEmpty() ? "" : "(" + unit + ")",
          descriptiveStatistics.getMin(), percentile.evaluate(25),
          percentile.evaluate(50), descriptiveStatistics.getMean(),
          percentile.evaluate(75), descriptiveStatistics.getMax());
    }

    instrumentSpecs.add(trial.instrumentSpec());

Examples of org.apache.commons.math.stat.descriptive.summary.Sum.evaluate()

        if (test(values, begin, length)) {
            Sum sum = new Sum();
            double sampleSize = length;

            // Compute initial estimate using definitional formula
            double xbar = sum.evaluate(values, begin, length) / sampleSize;

            // Compute correction factor in second pass
            double correction = 0;
            for (int i = begin; i < begin + length; i++) {
                correction += values[i] - xbar;

Examples of org.apache.commons.math.util.ContinuedFraction.evaluate()

                    return 1.0;
                }
            };
            ret = FastMath.exp((a * FastMath.log(x)) + (b * FastMath.log(1.0 - x)) -
                FastMath.log(a) - logBeta(a, b, epsilon, maxIterations)) *
                1.0 / fraction.evaluate(x, epsilon, maxIterations);
        }

        return ret;
    }

Examples of org.apache.commons.math3.stat.descriptive.UnivariateStatistic.evaluate()

    @Test
    public void testAllTechniquesSingleton() {
        double[] singletonArray = new double[] { 1d };
        for (EstimationType e : EstimationType.values()) {
            UnivariateStatistic percentile = getTestMedian(e);
            Assert.assertEquals(1d, percentile.evaluate(singletonArray), 0);
            Assert.assertEquals(1d, percentile.evaluate(singletonArray, 0, 1),
                    0);
            Assert.assertEquals(1d,
                    new Median().evaluate(singletonArray, 0, 1, 5), 0);
            Assert.assertEquals(1d,

Examples of org.apache.commons.math3.stat.descriptive.moment.Mean.evaluate()

                  LocalizedFormats.DIMENSIONS_MISMATCH_SIMPLE, length, yArray.length);
        } else if (length < 2) {
            throw new MathIllegalArgumentException(
                  LocalizedFormats.INSUFFICIENT_OBSERVED_POINTS_IN_SAMPLE, length, 2);
        } else {
            double xMean = mean.evaluate(xArray);
            double yMean = mean.evaluate(yArray);
            for (int i = 0; i < length; i++) {
                double xDev = xArray[i] - xMean;
                double yDev = yArray[i] - yMean;
                result += (xDev * yDev - result) / (i + 1);

Examples of org.apache.commons.math3.stat.descriptive.moment.StandardDeviation.evaluate()

        for (int i = 0; i < length; i++) {
            values[i] = start + i;
        }

        StandardDeviation stdDev = new StandardDeviation();
        return stdDev.evaluate(values);
    }

    @Override
    protected String getFunctionName()
    {
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.