Forum Discussion

mlowell's avatar
mlowell
New Member
9 years ago

Display time series data on line chart

Hi,

 

I am struggling to display some time based data on a line chart using PowerBI Desktop and haven't had any luck searching for a solution.

 

I have data as per the small sample below from a timesheet system displaying the Date, staffID, Clock in Time, Clock Out time.

 

I am looking to create a line chart displaying time of day on the X axis and number of staff on site on the Y axis for an individual day.

 

ANy help or a point in the right direction would be appreciated.

 

DateStaffIDManTimeInManTimeOut
4/4/17 0:0037654/4/17 7:004/4/17 16:54
4/4/17 0:0039424/4/17 7:004/4/17 15:30
4/4/17 0:0040394/4/17 7:004/4/17 15:30
4/4/17 0:0051914/4/17 7:004/4/17 16:54
4/4/17 0:0050834/4/17 7:014/4/17 16:22
4/4/17 0:0051634/4/17 7:014/4/17 13:54
4/4/17 0:0032244/4/17 7:154/4/17 15:42
4/4/17 0:0054424/4/17 7:154/4/17 16:32
4/4/17 0:0056014/4/17 7:154/4/17 15:55
4/4/17 0:0039414/4/17 7:184/4/17 16:38
4/4/17 0:0038454/4/17 7:304/4/17 15:15
4/4/17 0:0036474/4/17 7:334/4/17 15:08
4/4/17 0:0050574/4/17 7:334/4/17 14:39

4 Replies

  • deldersveld's avatar
    deldersveld
    Resident Rockstar

    If you've added the datetime to the Axis, it may be defaulting to a default date hierarchy. Try the setup in this screenshot as a starting point, and after adding the datetime field, click on the arrow and select the time value from the menu.

     

    • mlowell's avatar
      mlowell
      New Member

      Thanks deldersveld, 

       

      I can produce your results above, the key issue is the 'running sum' of the number of employees on site rather than simply graphing the time they clock on.

       

      In your example below, at 7:30 i should be showing 9 staff on site, sorry if that wasn't clear in the first post.

       

      I am expecting the result to look a lot like a bell curve.