I am using QGIS 2.18
I have a shapefile that contains data of each state of India, and the number of people per state following a particular religion. Each feature has the following attributes: name, total population, total hindu, total muslim, total christian, (there are 8 fields on religion)etc etc.Taken from census data.
I want to do stylize my map in several ways that involve finding out the religion with the maximum people in each state.
So basically, the styling function I'd need performs something like this:
Case when ~Hindu is max~ then color: color1 when ~christian is max~ then color: color2 ....
I've been trying to see if I can compare across fields and then return the field name of which the maximum value belongs to. But I cannot find any function that does that.
Any tips on how to do this?
PS I have not studied POSTGIS,grass etc, so it would be great if I could be given answers that do not require these. I will be studying it soon though, so if it is inevitable to use that I will. But I want to see what I can do now.