Forum Discussion
Need help with Member Retention based off 2 columns
- Anonymous4 years ago
Hi OpenMike13 ,
Please try this measure.
Member retention Rate = VAR _mindate = CALCULATE ( MIN ( 'Table'[CountDate] ), ALL ( 'Table'[CountDate] ) ) VAR _count1 = COUNTROWS ( 'Table' ) VAR _count2 = CALCULATE ( DISTINCTCOUNT ( 'Table'[contactid] ), FILTER ( ALL ( 'Table' ), 'Table'[CountDate] >= _mindate && 'Table'[CountDate] <= MIN ( 'Table'[CountDate] ) ) ) VAR _rate = DIVIDE(_count1,_count2) RETURN _rateAttached PBIX file for reference.
Best Regards,
Gao
Community Support TeamIf there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly. If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!
How to get your questions answered quickly -- How to provide sample data
Hi OpenMike13 ,
Please try this measure.
Member retention Rate =
VAR _mindate =
CALCULATE ( MIN ( 'Table'[CountDate] ), ALL ( 'Table'[CountDate] ) )
VAR _count1 =
COUNTROWS ( 'Table' )
VAR _count2 =
CALCULATE (
DISTINCTCOUNT ( 'Table'[contactid] ),
FILTER (
ALL ( 'Table' ),
'Table'[CountDate] >= _mindate
&& 'Table'[CountDate] <= MIN ( 'Table'[CountDate] )
)
)
VAR _rate = DIVIDE(_count1,_count2)
RETURN
_rate
Attached PBIX file for reference.
Best Regards,
Gao
Community Support Team
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly. If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!
How to get your questions answered quickly -- How to provide sample data