only add non zeor values

This commit is contained in:
2022-11-21 13:42:41 +01:00
parent d585093ffe
commit a10c7dd251

View File

@@ -56,7 +56,9 @@ public class ScatterAggregator implements CustomAggregator {
public void addValue(final long epochMilli, final long value) {
final long roundedEpochMilli = epochMilli - epochMilli % epochMillisPerPixel;
final long roundedValue = value - value % valuesPerPixel;
matrix2d.put(roundedEpochMilli, roundedValue, 1);
if (roundedEpochMilli > 0 && roundedValue >= 0) {
matrix2d.put(roundedEpochMilli, roundedValue, 1);
}
}
@Override