2

In QGIS i would like to create symbology for points layer where the symbology will take into account more than one parameter (currently two). i.e.: My points layer has street names and house numbers and i would like to have each street with a different symbol and each number with a different color. Each street_name+house_number is unique. I wouldn't mind if distant streets share symbols.

What will be the best way to achieve it in QGIS? Consider that Rule-based symbology is manual and i have many streets, i don't see it as a good solution for this specific problem.

Vince
  • 20,017
  • 15
  • 45
  • 64
Shai Efrati
  • 265
  • 1
  • 9

1 Answers1

2

There is no built-in method to automatically classify based on two different symbols with a symbology matrix in the end.

Data Defined Symbology

QGIS knows the concept of data defined symbology. This allows styling different aspects of the symbology each with an expression based on a different attribute. You can write a CASE statement for the line symbology (e.g. dash spaces) based on the street name and an expression that generates color values from the number. You activate data defined symbology by clicking the small symbol with a letter E to the right of the symbology control.

Python

You can write some python code that will create the symbology matrix for you and efficiently create a rule based symbology.

Matthias Kuhn
  • 27,780
  • 3
  • 88
  • 129
  • Thanks! i'll check later today. I do know that in ArcGIS you do have an option for that: Unique Values, Many Fields with up to 3 fields. I wonder if we just missed this option in QGIS. – Shai Efrati Aug 30 '15 at 11:27
  • Also - i saw this: http://christopherwesson.azurewebsites.net/2014/03/30/categorising-from-multiple-fields-in-qgis-2/ where he suggests to concatinate strings. I find it not completely suitable for that mission. – Shai Efrati Aug 30 '15 at 11:30
  • i couldn't find the data defined symbology - the only E i found was that sigma like sign that opens the functions window. Can you please guide me? – Shai Efrati Aug 31 '15 at 09:10
  • It is the sigma sign that opens the function window. See e.g. here – Matthias Kuhn Aug 31 '15 at 09:19
  • Weird - i can't see the small window you referenced to, and the sigma is just the Expression dialog. It doesn't help much in my case... thanks anyway! – Shai Efrati Sep 01 '15 at 06:11
  • The screenshot is from an old version. That's why. The "Expression dialog" is what you are looking for. The job left for you is to transform the field value into a symbology value equivalent. – Matthias Kuhn Sep 01 '15 at 06:13
  • Thanks for clarifying! as we discussed previously - it is still a hack like solution for my specific issue. – Shai Efrati Sep 01 '15 at 09:12