Forum Discussion
I'm stumped on analyzing data by date
- Anonymous5 years ago
Hi ChrisNelsonPE ,
For a bar chart, you try the measures.
Measure = CALCULATE(DISTINCTCOUNT('Table'[Visitor]),FILTER('Table',[VisitedOn]=MAX('Table'[VisitedOn])))Just use FILTER function to filter the dates which you want. MAX corresponds to the latest date, and MIN corresponds to the earliest date.
New sample pbix file is here.
Best Regards,
Stephen Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi ChrisNelsonPE ,
Could you please tell me what your expected result is?
Please provide me with more details about your table and your problem or share me with your pbix file from your Onedrive for Business.
Best Regards,
Stephen Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
- ChrisNelsonPE5 years ago
Helper I
Thanks, Anonymous . The forum software ate my original question and kept me from editing or replying to the topic for days. I started over at https://community.powerbi.com/t5/Desktop/I-m-stumped-on-analyzing-data-by-date/m-p/1529242/highlight/false#M628567 which I think has clear inputs and outputs.
- Anonymous5 years agoNot applicable
Hi ChrisNelsonPE ,
For the first expected result, put the VisitedOn column and the Visitor column to a table. Then select Count(Distinct) in the Visitor column as follows.
For the second expected result, put the VisitedOn column and the Visitor column to a table. Then select Lateset in the VisitedOn column as follows.
You can check more details from here.
Best Regards,
Stephen Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
- ChrisNelsonPE5 years ago
Helper I
Anonymous, thanks, that does produce the correct results. But I need charts, not tables. I tried to create a bar chart with the same process but some of the options aren't there.