I have the fowling data:
Client Count
Schizo Others Total
Hospitalized 76 687 763
Not Hospitalized 2100 18900 21000
I am trying to calculate % of Total for Hospitalized and Not Hospitalized group. Since I am doing client profile for both groups (in this case schizophrenia vs all other conditions), the % of Total needs to adjust dynamically. Meaning, if I switch from schizo group to gender or age group, the 763 and 21000 should be constant as my denominators.
Here is the desired result:
% of Total
Schizo Others Total
Hospitalized 10% 90% 100% (763)
Not Hospitalized 10% 90% 100%(21000)
Here are my calculations that didn’t give my the desired result:
Total Clients = DISTINCTCOUNT(Sampledata[Clientid])
Total Clients Hospitalized = CALCULATE(DISTINCTCOUNT(SampleData[Clientid]), (SampleData[AllHospitalized]="All Hospitalized"))
% Of Total Hospitalized = [Total Clients Hospitalized]/[Total Clients]
I appreciate any help and directions.
Thank You,
Helal