SLDService range rules building does not follow RangedClassifier specs, breaking quantile classification

Description

From the RangedClassifier javadoc:

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 /** * Classifies into ranges of minimum and maximum values. * * <p>The buckets are defined such that:<br> * min <= x < max * * <p>So if you provide the following min/max values:<br> * min = {3, 6, 9}<br> * max = {4, 10, 30}<br> * * <p>The classify function will classify items based on:<br> * 3 <= x < 4<br> * 6 <= x < 10<br> * 9 <= x <= 30<br> * * @author Cory Horner, Refractions Research */

Instead the SLDService builds rules with "low < x <= high", breaking the positioning of the values in the quantile classification (as the break values are normally actual values in the dataset). The result is most visible in classification over small datasets or datasets with many repeated values, less so in larger datasets.

Environment

None

Status

Assignee

Andrea Aime

Reporter

Andrea Aime

Triage

None

Fix versions

Affects versions

None

Components

Priority

Medium
Configure