Rolling Average
Thanks for sharing the details for the rolling average quick measure.
I get an incorrect result when I use a base value requires a different date field in the calculation.
For example, I'd like to calculate the rolling average for my base value 'FoundationCount' below. My main date table is CohortDate[Date] which points to several date fields in Cohort_Roster table including Cohort_Roster[FoundationsDate]. The relationship to Cohort_Roster[FoundationsDate] is inactive by default so I activate it when needed below.
FoundationsCount := CALCULATE( countx(Cohort_Roster,Cohort_Roster[FoundationsDate]), USERELATIONSHIP(CohortDate[Date],Cohort_Roster[FoundationsDate] ))
Can you advise any edits to the DAX code above where I could add 'USERELATIONSHIP' to pick up the correct date values?
Thanks.