cancel
Showing results for
Search instead for
Did you mean:
Regular Visitor

## Count ID and Chart Occurrence

I want to count how many times an ID shows up in a given time frame and show that as a chart. I created a column that converts the date into the week of the year. What I am trying to show is how many times someone came into the building in a given week.

Table_1

 ID Date Week 1234 1/1/2022 Week 1 1234 1/2/2022 Week 1 1235 1/1/2022 Week 1

 Chat

 Frequency 1 2 3 4 5 Week 1 1 2 Week 2 Week 3 ….
1 ACCEPTED SOLUTION
Community Support

HI @aslure,

I'm not so clear about your frequency field definitions, can you please share some detail about these? They will help us clarify your scenario and test to coding formula.

How to Get Your Question Answered Quickly

In addition, you can also try to use the following measure formula if helps:

``````formual =
CALCULATE (
COUNTA ( Table[ID] ),
ALLSELECTED ( Table ),
VALUES ( Table[Week] ),
VALUES ( Table[frequency] )
)``````

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.
3 REPLIES 3
Community Support

HI @aslure,

I'm not so clear about your frequency field definitions, can you please share some detail about these? They will help us clarify your scenario and test to coding formula.

How to Get Your Question Answered Quickly

In addition, you can also try to use the following measure formula if helps:

``````formual =
CALCULATE (
COUNTA ( Table[ID] ),
ALLSELECTED ( Table ),
VALUES ( Table[Week] ),
VALUES ( Table[frequency] )
)``````

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.
Super User

@aslure , With help from i ndependent date table and group by

Cnt measure = count(Table[ID])

//Idependent table

Bucket Table = Addcolumn( generateseries(1, 100,1), "Bucket Name", "Bucket " & format([value], "00"))

Countx(filter(values(table[Week]) , [Cnt measure] =Max('Bucket Table'[Value])), [CourseName])

Refer

Dynamic Segmentation Bucketing Binning
https://community.powerbi.com/t5/Quick-Measures-Gallery/Dynamic-Segmentation-Bucketing-Binning/m-p/1...

Dynamic Segmentation, Bucketing or Binning: https://youtu.be/CuczXPj0N-k

Power BI Features || Datamarts: https://youtu.be/8tskWsJTEpg || Field Parameters : https://youtu.be/lqF3Wa1FllE?t=70
Time Intelligence Decoded : https://youtu.be/aU2aKbnHuWs&t=145s
Did I answer your question? Mark my post as a solution! Appreciate your Kudos !! Proud to be a Super User! !!
Dashboard of My Blogs !! Connect on Linkedin !! Subscribe to my youtube Channel !!
Want To Learn Power BI | Beginners !! Advance Concepts !! Power BI For Tableau User !!
Regular Visitor

What are you referring to when you say [CourseName]?

## Helpful resources

Announcements

#### Check it Out!

Click here to learn more about the August 2022 updates!

#### The Power BI Community Show

Watch the playback when Priya Sathy and Charles Webb discuss Datamarts! Kelly also shares Power BI Community updates.

#### Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

Top Solution Authors
Top Kudoed Authors