# Rule Based Style

vector, feature, stylemap, filter, comparison

Use rule based styling to use different symbolizers for different feature groups.

This example uses four rules to render features. Rules are based on a feature attribute and determine which symbolizer is applied when rendering a feature. The rules in this example change which marker is used by providing an externalGraphic property in the symbolizer.

The features are labeled with the same attribute that determines the symbolizer used. You should be able to confirm that the graphic color corresponds to the range of numbers given below.

- 0 <= blue < 25
- 25 <= green < 50
- 50 <= gold <= 75
- 75 < red <= 100

See the style-rules.js source to see how this is done.