Forum Discussion
Anonymous
6 years agoNot applicable
Cumulative count measure
I looking to creating a cumulative measure on the patient count. Patient Count column is count(table[patienid])
- 6 years ago
Hi Anonymous
Try this one:
RunningTotal1 = VAR __year = MAX(TrendingTable[Date_Start_Statusdate].[Year]) RETURN CALCULATE( count(TrendingTable[vw_AccrualsList.patientId]), FILTER(allselected(TrendingTable), TrendingTable[Date_Start_Statusdate] <= MAX(TrendingTable[Date_Start_Statusdate]),values(TrendingTable(Year)) ) )
Greg_Deckler
Community Champion
6 years agoAnonymous - Can you just use the Running Total Quick Measure that is built into the Desktop? In Fields, click the ellipses next to Patient Count and choose Quick Measure and then Running Total.
Anonymous
6 years agoNot applicable
I added month to and still did not work
RunningTotal =
CALCULATE(
COUNTA('TrendingTable'[vw_AccrualsList.patientId]),
FILTER(
CALCULATETABLE(
SUMMARIZE(
'TrendingTable',
'TrendingTable'[CurrentStatusDate].[MonthNo],
'TrendingTable'[CurrentStatusDate].[Month]
),
ALLSELECTED('TrendingTable')
),
ISONORAFTER(
'TrendingTable'[CurrentStatusDate].[MonthNo], MAX('TrendingTable'[CurrentStatusDate].[MonthNo]), DESC,
'TrendingTable'[CurrentStatusDate].[Month], MAX('TrendingTable'[CurrentStatusDate].[Month]), DESC
)
)
)- Anonymous6 years agoNot applicable
@amitchandak
Is there any solution for this?