1

It's possible in QGIS to add a symbology for lines which is based on a field.

This symbology may then use a method with either:

  • color
    or
  • size

qgis method for symbology

But is it possible to use both, i.e. colors AND size based on the same attribute field for classification?

It seems possible to define it with method "size" and then manually change the color (or the inverse; method "color" and specifying width manually) for each entry but it's rather tedious.

1

You can sort of do this by setting the width in the "Symbol" dialogue - at least I think this can be used to do what you want.

Set the classification to color and classify your data. Then click on change symbol and select the line type (default Simple Line). From this dialogue you can set a pen width based on an attribute. It won't by default allow you to define an expression but if you use the 'width assistant' and then go back into the menu it will let you use the edit and this brings up the standard expression generator.

enter image description here

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.