Now, I must admit that I'm not at all comfortable explaining DAX measures. Although, the attached workbook does what you need (I believe) by adding the year into the FILTER, I feel that there must be a better way to do this.
Thank you,
You've been very helpfull, that looks like it works the way I'd like.
I'll keep studying and doing examples, hopefully it will start to click.
If you create a date table, you can then use time intelligence functions. You can create a compounding measure (Compounded Percent) using:
=VAR CP =PRODUCTX(Table2, 1+Table2[%gain])
RETURN IF(ISBLANK(CP),BLANK(),CP-1)
then your other two measures are:
CompoundYTD
=IF(COUNTROWS(Table2)>0,TOTALYTD([Compounded Percent],'Calendar'[Date]),BLANK())
(the COUNTROWS is just to hide values for months where you don't have data)
CompoundMTD
=TOTALMTD([Compounded Percent],'Calendar'[Date])
Thx to @Velouria!!
I've added the time intelligent solution to the file.
Well, I'm certainly learning a lot here!
Thanks very much Velouria and Riny