I've the 8 social classes (see under) for +- 900 polygons. I would like to create a new column that keep only name of the main social class for each row (based on the percentage). After that I would like to set a color for each polygon based on the major social class in it.
| | bureau | CS1 | CS2 | CS3 | CS4 | CS5 | CS6 | CS7 | CS8 |
|---|--------|----------------------|------------------|------------------|------------------|------------------|------------------|------------------|------------------|
| 1 | 101 | 0.000543797261927398 | 6.39760099954826 | 35.3448745188225 | 12.4775915818504 | 7.0610910561502 | 2.78350275427263 | 17.5344485748163 | 18.4706452869407 |
| 2 | 102 | 0.0833792083846865 | 4.71178099155645 | 38.947249168602 | 12.664389902742 | 11.382192650638 | 2.39111672203692 | 16.1342822915544 | 13.6751866634374 |
| 3 | 103 | 0.177533456592499 | 4.44507934549473 | 39.2964921235435 | 15.4694031513017 | 11.2500227953552 | 2.60237087604638 | 13.7660576214535 | 13.0155179780742 |
| 4 | 104 | 0.15873318630476 | 3.98029853494405 | 37.1732526731557 | 15.6841983264699 | 12.9923578110956 | 3.4037063750489 | 13.2499374112967 | 13.3569488994092 |
| 5 | 105 | 0.100023025825703 | 3.80769682422482 | 34.0805398317955 | 15.3453144362231 | 15.6672496204983 | 3.67494171412793 | 13.9390141521583 | 13.4010089709952 |
I think I need to use the field calculator but I didn't use it for a long time so I'm stuck with the realization !