It the TOTALYTD function which is causing the issues here.
It has quite unexpected behaviour depending on what date context you have in your report.
I can’t quite see what you have in your report because I don’t see a slicer.
But for example, if for instance your date table has dates in a particular year but then there is no data and your filter extend to that time frame that you total will be zero.
Unfortunately I cannot upload an example file as I am using live company data. This is isn’t helpful in this situation but I have decided to do this as I think this will give me good “real world” practice while I learn Power BI.
I didn’t have any slicer on this page but when I added it and selected the max date on the slicer to today, it worked so you are correct in where the problem is originating from. As a test, I also removed all other tabs from the report to ensure there was no conflict elsewhere but this made no change. The dates table I am using is the one you suggested in the training and it runs 2018 & 2019 full calendar years.
Since I don’t want to have a slicer on the page for sales YTD & PY YTD, want these to update automatically, I have tried a few tweaks to the formulas with no success.
Am I using the best formulas for what I am trying to achieve? I think the YTD formula is the best as this comes from your video on preventing YTD projecting forward, but maybe the PY YTD formula is indirectly treating the TOTALYTD function incorrectly?