Forum Discussion
Values different on table/graph visuals
I'm trying to figure out the % of sessions that clients have missed. When calculating this in a table the results are correct, but when I put it in a graph visual it states the precentage a lot lower just on the month of feburary. I've found out that this is due to 3 sessions on the 28th of Feb not being included in the calculation. Can someone please advise? The data type is time/date, I can't change this to just date as I need the time to be referenced elsewhere on the dashboard.
3 Replies
- Greg_DecklerCommunity Champion
elinevans Can you share your formula for your % and are you able to share sample data?
- elinevansHelper I%FirstSessionDNA = divide([CountDNAFirstSessions], [CountAllFirstSessions])CountAllFirstSessions = CALCULATE(count(Sessions2[Reference]),FILTER(Sessions2, Sessions2[Start] <=max(DateTable[Date]) && Sessions2[Start] >= min(DateTable[Date]) && Sessions2[FirstSession]=1))CountDNAFirstSessions = CALCULATE(count(Sessions2[Reference]), filter(Sessions2, Sessions2[SessionOutcome] = "Did Not Attend (DNA)"),FILTER(Sessions2, Sessions2[Start] <=max(DateTable[Date]) && Sessions2[Start] >= min(DateTable[Date]) && Sessions2[FirstSession]=1))Where Sessions2[FirstSession]=1 just incidcates that it's the first session per client. And the DateTable is just a calendar table which is used on a slicer.Unfortunately it's really hard to give the exact data as it has a lot of sensitive data however it's in the following format:
Client ID Refernce Start FirstSession Session outcome 1234 152756873 02/02/22 15:00 1 Did not attend (DNA) 1234 2723487 05/02/2022 17:00 0 Attended 8594 735459654564 06/05/2021 1 Attended - elinevansHelper I
When in the table visual it shows the activities that occured on the 28th Feb, but when I look at the 'raw' data nothing comes up when the table is filtered to the 28th feb. I'm very confused and feel I'm going insane