I have a layer with road segments that come in five different classes and each have a value. I am trying to get a graduated color for the values (say, light blue for low and dark blue for high values) and at the same time make the highways (class 0) thicker than local roads (class 4) etc.

Now, usually I visualize the colors using about 10 classes (quantiles), so I'd end up defining somewhere around 50 rules: road class 1, value 0-100 - road class 1, value 100-500 and so on.

Is there a way to get there any quicker?

Using Version 2.18.10

  • 2
    What about duplicating the layer and having one with categorised style and the other with graduated? – Joseph Feb 6 '18 at 9:59

Not sure if this is what you are aiming to:

(1) Select Graduate and choose "values" for Columns.

(2) Set your Color ramp to Blues, perhaps

(3) Click on Symbol: --Change... button to activate Symbol selector

(4) Click on the small Epsilon button (i.e. Data defined override) right to Width

(5) Enter suitable expression something like: (5 - "classes") * 2. (Probably 2 is too much...)

enter image description here

  • 1
    This totally did it! Thanks a lot; this was a great help! – ThinWhiteDuke Feb 6 '18 at 14:14
  • @ThinWhiteDuke - Don't forget to accept this answer by clicking the green-faded tick on the left-hand side :) – Joseph Feb 7 '18 at 12:40

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.