Today I finished up the documentation for gt-brewer.
Documentation harmed in the making of this post:
- Classifier - added several examples including how to make them by hand rather than from a feature collection
- FeatureCollection - updated the classification functions to list all the different options available
- ColorBrewer - step through from website, palette selection through to generation of an style
As is often the case the wiki page I am starting from was:
a) written by me (so is of dubious quality)
b) was cut and pasted from the gt-user list
c) contains a single code example
d) which was being used to quickly answer a question
So the detective work is to sort out what the code example was trying solve and provide some context explaining what is going on and how it works.
For today we had two key concepts Classifier and ColorBrewer.
Captures a group of values (either expressed explicitly or as a range) providing a title to each group
Combination of ColorBrewer and StyleGenerator can be used to generate a FeatureTypeStyle according to your instruction.
This builds on the excellent website http://colorbrewer2.org/ which defines the above palettes for use.