That helped a lot, I checked out your tutorial and used the code you sent.
However, I get very different results when using the formula you suggested, and when i tried to copy the forumla from your tutorial. I can't quite figure out why and how the results are so different from using seemingly similar logic behind the two formulas.
Do you think you could explain how this could be happening? If you could, you'd be better than ChatGPT, because it failed to explain to me hahah.
The first matrix uses this measure:
Average visit = AVERAGEX(SUMMARIZE(PRC,PRC[APPT_DATE].[Date]),COUNT(PRC[ENC_TYPE_TITLE]))