Solved

Stacked Chart in Excel

Posted on 2013-10-29
2
257 Views
Last Modified: 2013-10-30
Hello all,

I have a spreadsheet of the times people logged in and out of a room. Taking two as an example:

Name      Date             Function      Start              End             Duration
Tom      07/10/2013      Absent      08:04      08:56      00:52
Tom      07/10/2013      Present      08:56      08:59      00:03
Tom      07/10/2013      Absent      08:59      10:02      01:03
Tom      07/10/2013      Present      10:02      10:12      00:10
Tom      07/10/2013      Absent      10:12      11:49      01:37
Tom      07/10/2013      Present      11:49      12:12      00:23
Tom      07/10/2013      Absent      12:12      13:39      01:27
Tom      07/10/2013      Present      13:39      13:50      00:11
Tom      07/10/2013      Absent      13:50      14:14      00:24
Tom      07/10/2013      Present      14:14      15:34      01:20
Tom      08/10/2013      Present      07:52      10:59      03:07
Tom      08/10/2013      Absent      10:59      12:58      01:59
Tom      08/10/2013      Present      12:58      13:24      00:26
Tom      08/10/2013      Absent      13:24      14:13      00:49
Tom      08/10/2013      Present      14:13      15:39      01:26
Tom      09/10/2013      Present      07:58      09:06      01:08
Tom      09/10/2013      Absent      09:06      12:27      03:21
Tom      09/10/2013      Present      12:27      13:26      00:59
Tom      09/10/2013      Absent      13:26      14:03      00:37
Tom      09/10/2013      Present      14:03      15:20      01:17
Tom      10/10/2013      Present      09:01      09:21      00:20
Tom      10/10/2013      Absent      09:21      10:10      00:49
Tom      10/10/2013      Present      10:10      10:12      00:02
Tom      10/10/2013      Absent      10:12      12:16      02:04
Tom      10/10/2013      Present      12:16      12:42      00:26
Tom      10/10/2013      Absent      12:42      13:59      01:17
Tom      10/10/2013      Present      13:59      16:03      02:04
Tom      11/10/2013      Present      07:44      09:37      01:53
Tom      11/10/2013      Absent      09:37      11:42      02:05
Tom      11/10/2013      Present      11:42      12:41      00:59
Tom      11/10/2013      Absent      12:41      14:08      01:27
Tom      11/10/2013      Present      14:08      14:38      00:30
Tom      14/10/2013      Present      11:24      11:25      00:01
Tom      14/10/2013      Absent      11:25      14:16      02:51
Tom      14/10/2013      Present      14:16      15:25      01:09
Pat      07/10/2013      Present      09:05      09:07      00:02
Pat      07/10/2013      Absent      09:07      10:07      01:00
Pat      07/10/2013      Present      10:07      10:14      00:07
Pat      07/10/2013      Absent      10:14      11:14      01:00
Pat      07/10/2013      Present      11:14      12:53      01:39
Pat      07/10/2013      Absent      12:53      13:33      00:40
Pat      07/10/2013      Present      13:33      13:51      00:18
Pat      07/10/2013      Absent      13:51      14:39      00:48
Pat      07/10/2013      Present      14:39      15:33      00:54
Pat      08/10/2013      Present      07:50      09:53      02:03
Pat      08/10/2013      Absent      09:53      11:32      01:39
Pat      08/10/2013      Present      11:32      12:13      00:41
Pat      10/10/2013      Present      09:01      09:32      00:31
Pat      10/10/2013      Absent      09:32      11:29      01:57
Pat      10/10/2013      Present      11:29      11:37      00:08
Pat      10/10/2013      Absent      11:37      14:08      02:31
Pat      10/10/2013      Present      14:08      15:57      01:49
Pat      11/10/2013      Present      08:02      09:56      01:54
Pat      11/10/2013      Absent      09:56      10:26      00:30
Pat      11/10/2013      Present      10:26      10:52      00:26
Pat      11/10/2013      Absent      10:52      11:51      00:59
Pat      11/10/2013      Present      11:51      12:38      00:47
Pat      11/10/2013      Absent      12:38      14:53      02:15
Pat      11/10/2013      Present      14:53      15:52      00:59
Pat      14/10/2013      Present      08:40      10:13      01:33
Pat      15/10/2013      Absent      10:13      11:43      01:30
Pat      16/10/2013      Present      11:43      13:02      01:19
Pat      17/10/2013      Absent      13:02      14:12      01:10
Pat      18/10/2013      Present      14:12      15:35      01:23

I'd like to present these in a horizontal bar chart such that:


                              [Date]

Tom | PPPPAAPPPAAAAAPPAAAAAA....
        |
        |
Pat   |PAAAPPPAPPPAAAAPPAAAPPAAA..
 
         <Time Start> -----------------------<Time End>

Where 'P' is the colour of the bar representing 'Present' and 'A' is the colour of the bar representing 'Absent'.

I've been at this trying as many permutations in Excel as possible without success. I've googled it and looked for solutions here without success. Can anyone advise, please?

Regards,

Seamie
0
Comment
Question by:Seamie_
2 Comments
 
LVL 21

Accepted Solution

by:
Ejgil Hedegaard earned 400 total points
ID: 39610345
Here is a setup for it.
See attached workbook.
Stacked-Chart-present-absent.xlsx
0
 

Author Comment

by:Seamie_
ID: 39611073
Wow! hgholt, that's amazing and so concise! I wondered whether I had described the issue sufficiently. Whether or not, you answered the problem excellently.

I'm looking forward to parsing out the solution.

Many thanks.

Seamie
0

Featured Post

Problems using Powershell and Active Directory?

Managing Active Directory does not always have to be complicated.  If you are spending more time trying instead of doing, then it's time to look at something else. For nearly 20 years, AD admins around the world have used one tool for day-to-day AD management: Hyena. Discover why

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Dropbox in Windows Server 2008 4 31
Creating An Intelligent Dropdown 8 30
Msgbox tickler 10 25
Problem to file 5 16
This code takes an Excel list of URL’s and adds a header titled “URL List”. It then searches through all URL’s in column “A”, looking for duplicates. When a duplicate is found, it is moved to the top of the list. The duplicate URL’s are then highlig…
This article descibes how to create a connection between Excel and SAP and how to move data from Excel to SAP or the other way around.
Graphs within dashboards are meant to be dynamic, representing data from a period of time that will change each time the dashboard is updated with new data. Rather than update each graph to point to a different set within a static set of data, t…
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…

778 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question