List of usage examples for org.jfree.data.general DatasetUtils createConsolidatedPieDataset
public static PieDataset createConsolidatedPieDataset(PieDataset source, Comparable key, double minimumPercent, int minItems)
From source file:org.jfree.data.general.DatasetUtils.java
/** * Creates a new pie dataset based on the supplied dataset, but modified * by aggregating all the low value items (those whose value is lower * than the {@code percentThreshold}) into a single item with the * key "Other"./* w ww. ja v a 2s . co m*/ * * @param source the source dataset ({@code null} not permitted). * @param key a new key for the aggregated items ({@code null} not * permitted). * @param minimumPercent the percent threshold. * * @return The pie dataset with (possibly) aggregated items. */ public static PieDataset createConsolidatedPieDataset(PieDataset source, Comparable key, double minimumPercent) { return DatasetUtils.createConsolidatedPieDataset(source, key, minimumPercent, 2); }