I'm trying to use a Treemap for showing average values from a quick measure for a category and its details. However, it seems that the Treemap is sorting the category over the sum of the averages of each detail instead of the averages overall.
My Treemap looks like this:
My quick measure looks like this:
FactCampusCH looks like this:
FactCampusQtdDocentes looks like this:
I noticed that each category block (e.g. campuses CTC, CCS, CFH, CCS, etc.) is sorted over the sum of each of their details (average working hours of Departments) but I wanted the biggest average to appear first and not the biggest sum. This makes it seems that "CTC" has bigger average working hours than "CTE" (because CTC has more Departments, making the sum of its averages bigger than CTE), which is not true.
If I take the details off, the Treemap looks (correctly) like this (CTE first, CDS second, etc.):
I wanted to maintain this correct order with the details. But once I put on the details the Treemap changes the ordering 😞
Any ideas on how can I achieve this?