Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
krscott409
New Member

Punch Data Visualization

Hello, 

I am trying to understand how I might be able to visualize punch data on an area chart but automate the calculation in DAX or M. Ultimately, I want this data on an area chart with time on the time of day on the X-axis and count of working employees on the Y-axis (I will be plotting this data along with 15-minute interval PoS transaction data too).

I have done this in the past in a manual way by listing out all of the times of the day (in 15-minute increments) and placing a "1" for each count of employees working during that 15-minute interval. My question is, is there a way to write DAX or M to get the raw data so that the area chart can consume and plot this data? 

 

Raw Data:

Employee IDPunch StartPunch EndBreak StartBreak End
12349:15 am5:00 pm12:30 pm1 pm
12359 am4 pmnullnull
12368 am3 pm11 am11:30 am

 

Manual Example:

Employee ID88:158:308:459:009:159:309:4510
1234     1111
1235    11111
1236111111111
1 ACCEPTED SOLUTION
Anonymous
Not applicable

HI @krscott409,

You can create a new time table with fifteen minute as interval, and use its time field with raw table employee field to create a matrix.(time to column, employee to row)

After these steps, you can write a measure formula to lookup raw table records based on the current employee and corresponding time values to return flag and use on matrix value field.

1.png

Regards,

Xiaoxin Sheng

View solution in original post

1 REPLY 1
Anonymous
Not applicable

HI @krscott409,

You can create a new time table with fifteen minute as interval, and use its time field with raw table employee field to create a matrix.(time to column, employee to row)

After these steps, you can write a measure formula to lookup raw table records based on the current employee and corresponding time values to return flag and use on matrix value field.

1.png

Regards,

Xiaoxin Sheng

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors