public void setMaxMinOverall() { List<Float> values = new ArrayList<Float>(); if (valueIndex.mask) { for (Site s : sitesMask) { for (Double d : s.respValues) values.add(d.floatValue()); } } else { for (Site s : sites) { for (Double d : s.respValues) values.add(d.floatValue()); } } paint.max = Collections.max(values).floatValue(); paint.min = Collections.min(values).floatValue(); }
public void setMaxMin() { List<Float> values = new ArrayList<Float>(); if (valueIndex.mask) { for (Site s : sitesMask) { values.add(s.respValues.get(valueIndex.idx).floatValue()); } } else { for (Site s : sites) { values.add(s.respValues.get(valueIndex.idx).floatValue()); } } paint.max = Collections.max(values).floatValue(); paint.min = Collections.min(values).floatValue(); }
public void updateColors(float[] fracs, Color[] colors) { float[] select; if (colors.length == 2) select = twoColors; else select = threeColors; if (fracs == null) fracs = select; paint.setLinearGradient(0, 0, 0, 150, fracs, colors); }