5

I am using QGIS 2.18.18

I have a map of rivers and I want to style them based on their width. I have width as an attribute of the rivers layer.

Just as we can style colors by category or graduated styling, I want to do the same with width. Currently I use an expression editor for data driven override (circled in the picture) after which I have to manually classify everything. If classification could be done by quantiles, jenks or other breaks automatically, then it would be easier for me to see which classification has what effect on my map. As I said, that is possible with color, but I cannot figure out how to do it with width

If there is a way to do it without code that would be great, as I haven't learnt that yet. If there isn't, then I'll implement it once I learn code.

enter image description here

4

You can use graduted stylings for color and also size when using point or line features. In case of lines the size is used to classify the width. There you find also the options for natural breaks and other classifications.

enter image description here

  • Haha thanks. I totally skipped over it while using graduated – Dhaval Shukla Apr 23 '18 at 8:24
0

Go to Symbology, Single Symbol, Simple Line and click to Edit:

Edit line stroke width

Then open the option 'Fields and values' and refer to the attribute name containing the pen widths. Pen widths based on attribute data, Natural Earth rivers data set

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.