本文整理汇总了Java中org.apache.commons.math3.stat.descriptive.StatisticalSummaryValues类的典型用法代码示例。如果您正苦于以下问题:Java StatisticalSummaryValues类的具体用法?Java StatisticalSummaryValues怎么用?Java StatisticalSummaryValues使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
StatisticalSummaryValues类属于org.apache.commons.math3.stat.descriptive包,在下文中一共展示了StatisticalSummaryValues类的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: reduce
import org.apache.commons.math3.stat.descriptive.StatisticalSummaryValues; //导入依赖的package包/类
@Override
public void reduce(List<RevisionProcessor> workerProcessors) {
List<SummaryStatistics> emptyStatisticsList = new ArrayList<SummaryStatistics>();
List<SummaryStatistics> inconsistentStatisticsList = new ArrayList<SummaryStatistics>();
List<SummaryStatistics> jsonExceptionStatisticsList = new ArrayList<SummaryStatistics>();
List<SummaryStatistics> nullPointerExceptionStatisticsList = new ArrayList<SummaryStatistics>();
List<SummaryStatistics> newJsonStatisticsList = new ArrayList<SummaryStatistics>();
List<SummaryStatistics> oldJsonStatisticsList = new ArrayList<SummaryStatistics>();
List<SummaryStatistics> redirectStatisticsList = new ArrayList<SummaryStatistics>();
for (RevisionProcessor processor: workerProcessors) {
JsonProcessor jsonProcessor = (JsonProcessor) processor;
emptyStatisticsList.add(jsonProcessor.getEmptyJsonStatistics());
inconsistentStatisticsList.add(jsonProcessor.getInconsistentJsonXMLStatistics());
jsonExceptionStatisticsList.add(jsonProcessor.getJsonExceptionStatistics());
nullPointerExceptionStatisticsList.add(jsonProcessor.getNullPointerExceptionStatistics());
newJsonStatisticsList.add(jsonProcessor.getNewJsonStatistics());
oldJsonStatisticsList.add(jsonProcessor.getOldJsonStatistics());
redirectStatisticsList.add(jsonProcessor.getRedirectStatistics());
}
StatisticalSummaryValues emptyStatistics = AggregateSummaryStatistics.aggregate(emptyStatisticsList);
StatisticalSummaryValues inconsistentStatistics = AggregateSummaryStatistics.aggregate(inconsistentStatisticsList);
StatisticalSummaryValues jsonExceptionStatistics = AggregateSummaryStatistics.aggregate(jsonExceptionStatisticsList);
StatisticalSummaryValues nullPointerExceptionStatistics = AggregateSummaryStatistics.aggregate(nullPointerExceptionStatisticsList);
StatisticalSummaryValues newJsonStatistics = AggregateSummaryStatistics.aggregate(newJsonStatisticsList);
StatisticalSummaryValues oldJsonStatistics = AggregateSummaryStatistics.aggregate(oldJsonStatisticsList);
StatisticalSummaryValues redirectStatistics = AggregateSummaryStatistics.aggregate(redirectStatisticsList);
logger.info("Number of revisions with empty 'text' element: " + emptyStatistics.getN());
logger.info("Number of revisions with inconsistent JSON/XML item id: " + inconsistentStatistics.getN());
logger.info("Number of revisions whose 'text' element could not be parsed: " + jsonExceptionStatistics.getN());
logger.info("Number of revisions which threw a NullPointerException: " + nullPointerExceptionStatistics.getN());
long totalNumberOfFailures = emptyStatistics.getN() + inconsistentStatistics.getN() + jsonExceptionStatistics.getN() + nullPointerExceptionStatistics.getN();
logger.info("Total number of revisions whose item document was discarded: " + totalNumberOfFailures);
logger.info("Number of revisions in new JSON format: " + newJsonStatistics.getN());
logger.info("Number of revisions in old JSON format: " + oldJsonStatistics.getN());
logger.info("Number of revisions which represent a redirect: " + redirectStatistics.getN());
long totalNumberOfSuccesses = newJsonStatistics.getN() + oldJsonStatistics.getN() + redirectStatistics.getN();
logger.info("Total number of revisions whose item document was successfully parsed: " + totalNumberOfSuccesses);
}
示例2: getSystemStats
import org.apache.commons.math3.stat.descriptive.StatisticalSummaryValues; //导入依赖的package包/类
public StatisticalSummaryValues getSystemStats() {
// return this.aggregateStatsPerIndividual;
return this.overallSummaryStatsPerIndividual.aggregate;
}
示例3: getSystemStats
import org.apache.commons.math3.stat.descriptive.StatisticalSummaryValues; //导入依赖的package包/类
public StatisticalSummaryValues getSystemStats();