+ Reply to Thread
Results 1 to 25 of 25

Chart showing date and names on a time axis

  1. #1
    Forum Contributor
    Join Date
    07-05-2012
    Location
    Stockholm
    MS-Off Ver
    Excel 2010
    Posts
    162

    Chart showing date and names on a time axis

    Hi guys,

    I'm trying to create a chart/matrix where you should be able to see a list of names on the y-axis and a time line (dates) on the x-axis. Each name (y-axis) should have a "marker" along the x-axis aligned with the name, where a date is displayed on the side of the marker.

    The whole idea is to create a chart (or similar) where you can easily see when you have last contacted/communicated with a certain person.

    I've attached a "mock up" of how I suggest it can look, but I've had no luck what so ever in creating this on my own.

    Anyone got any bright ideas?
    Attached Files Attached Files

  2. #2
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,430

    Re: Chart showing date and names on a time axis

    Use a combination of Bar and Line.

    Start with a bar chart to get the names on the vertical axis.
    Set primary value axis to have fixed start and end dates.
    Add line series to secondary axis.
    Display secondary horizontal axis.
    Fix secondary category axis to have same fixed dates.
    Fix Secondary value axis to number of categories on primary axis

    Format bars and lines and data labels on line series.
    Attached Files Attached Files
    Cheers
    Andy
    www.andypope.info

  3. #3
    Forum Contributor
    Join Date
    07-05-2012
    Location
    Stockholm
    MS-Off Ver
    Excel 2010
    Posts
    162

    Re: Chart showing date and names on a time axis

    Hi Andy!
    Thanks ever so much! This looks really good!

    Is it also possible to add a generic line (the red line in my mock up) that shows where "today" is in the chart?

  4. #4
    Forum Contributor
    Join Date
    07-05-2012
    Location
    Stockholm
    MS-Off Ver
    Excel 2010
    Posts
    162

    Re: Chart showing date and names on a time axis

    Hi again,

    If I want to add more names and dates to the chart, how do I do that? I've managed to add more names and the bar, but the blue circle and date box do not appear when adding more names.

  5. #5
    Forum Contributor
    Join Date
    07-05-2012
    Location
    Stockholm
    MS-Off Ver
    Excel 2010
    Posts
    162

    Re: Chart showing date and names on a time axis

    Hi again for the 3rd time

    In the attached file I would like to add a few more things if possible.
    1. A vertical timeline that represents today's date
    2. Another circle (other color) that shows a new (later) date (next communications date)

    Any suggestions?
    Attached Files Attached Files

  6. #6
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,430

    Re: Chart showing date and names on a time axis

    Add extra series for future events.

    For Today line use Minus 100% error line.
    Attached Files Attached Files

  7. #7
    Forum Contributor
    Join Date
    07-05-2012
    Location
    Stockholm
    MS-Off Ver
    Excel 2010
    Posts
    162

    Re: Chart showing date and names on a time axis

    Thanks ever so much Andy! Really good work! This will be very helpful for me.

    One last questions though. If I change (extend) the x-axis maximum value to one more year (2014-01-01), the "event bar" for some reason extends beyond the blue event point. I can't seem to change this so it looks correct. Any thoughts?

    Cheers!

  8. #8
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,430

    Re: Chart showing date and names on a time axis

    did you update both primary and secondary axes?

  9. #9
    Forum Contributor
    Join Date
    07-05-2012
    Location
    Stockholm
    MS-Off Ver
    Excel 2010
    Posts
    162

    Re: Chart showing date and names on a time axis

    Ah, my mistake. It's working now.

    Thanks a million! You're a star!

  10. #10
    Forum Contributor
    Join Date
    07-05-2012
    Location
    Stockholm
    MS-Off Ver
    Excel 2010
    Posts
    162

    Re: Chart showing date and names on a time axis

    Hi again!

    Yet another issue ha arisen. Now I am trying to link the chart to the actual dates on the "Stakeholders Sheet". The dates works fine, but when I filter it all looks very strange. I think it's got to do with the Y-pos list on the "Data sheet" but I can't find a way to solve so it.

    So I want the chart to be generic and be able to only show the names that are included after filtering (like the first chart (Stakeholder Matrix)).
    Is this possible?

    Cheers!
    Attached Files Attached Files

  11. #11
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,430

    Re: Chart showing date and names on a time axis

    You have only 1 series linked to the Stakeholder data sheet.

    You also need to filter the Data sheet. This would include adjusting the YPOS values.

  12. #12
    Forum Contributor
    Join Date
    07-05-2012
    Location
    Stockholm
    MS-Off Ver
    Excel 2010
    Posts
    162

    Re: Chart showing date and names on a time axis

    Hi,
    Ok, so it's not possible to have everything on the stakeholder sheet so that I don't need to filter on two places?

  13. #13
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,430

    Re: Chart showing date and names on a time axis

    Chart uses xy-scatter instead of lines. This allows for X and Y values from same table as dates.
    YPos uses SUBTOTAL formula to handle filtered rows.

    Chart requires chart refresh code in order to update the secondary Y axis.
    I have used the sheet activate event to do this.
    Attached Files Attached Files

  14. #14
    Forum Contributor
    Join Date
    07-05-2012
    Location
    Stockholm
    MS-Off Ver
    Excel 2010
    Posts
    162

    Re: Chart showing date and names on a time axis

    Hi, and once again thank you for your help.

    When I filter it reduces the number of blue circles to the same number of names which is very good. However, they don't align in the chart which makes it hard to read. It seems as it has something to do with the second x-axis maximum values. It looks good (aligned) if I chose the fixed maximum value to be the same as the number of names. Is it possible to make the maximum value to automatically update?

    Cheers!

  15. #15
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,430

    Re: Chart showing date and names on a time axis

    There is already code in the example to update the secondary value axis.
    Have you enabled macros?

    If I remove all filtering the axis max=14
    If I filter Supporter the axis max =11 (although 10 is the last value shown)

  16. #16
    Forum Contributor
    Join Date
    07-05-2012
    Location
    Stockholm
    MS-Off Ver
    Excel 2010
    Posts
    162

    Re: Chart showing date and names on a time axis

    Fantastic! I must have missed enabling the macros. Now it works fine!

    BTW, do you know if it's possible to have the colors of the bubbles in the first chart (Stakeholder Matrix) to automatically update to be the same as the "Support" column on the Stakeholder sheet?

    So for instance, if name 13 is a "blocker" (red) the circle next to the name in the chart should also be red. At the moment I've only changed the colors manually. But it would be gold if that could be done automatically.

    In any case, thanks a million for your genius help!

    Cheers!

  17. #17
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,430

    Re: Chart showing date and names on a time axis

    add some more columns to the table to provide the Y value for each dot style, this will provide you with 3 series.

    Add additional series to hold data label name for all points. The data labels are linked to the range of text at the far right of the table.
    Attached Files Attached Files

  18. #18
    Forum Contributor
    Join Date
    07-05-2012
    Location
    Stockholm
    MS-Off Ver
    Excel 2010
    Posts
    162

    Re: Chart showing date and names on a time axis

    Thanks!

    How do I add more rows to both charts? Say I want to always have the possibility to add 50 names to the list that should also display in the charts. I tried just copying the rows but I get a "data array" error and I can't seem to add anymore rows into the charts.

    Any ideas?

  19. #19
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,430

    Re: Chart showing date and names on a time axis

    Start by amending and extending the array formula in column AJ.

    The Extend the other columns in the table, making sure the formula are referencing the correct cells.
    Then update the chart data series ranges to reference the new rows.

  20. #20
    Forum Contributor
    Join Date
    07-05-2012
    Location
    Stockholm
    MS-Off Ver
    Excel 2010
    Posts
    162

    Re: Chart showing date and names on a time axis

    Hmm, I really wish for once I could reply and say, "No probs Andy! I got it" ...Unfortunately my skills are apparently equal to an onion.

    When I try to amend and extending the formula I get the message "You can not change part of an array". I've tried different ways of changing it but no luck. Has it got anything to do with that some of the rows are hidden? Why are they btw?

    Cheers!

  21. #21
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,430

    Re: Chart showing date and names on a time axis

    Rows would only be hidden if the Support filter was still applied.

    Start by removing any current filter from the table.
    Assuming you want to extend the rows from 16 to 32.
    Select range AJ3:AJ32 then adjust the formula

    =SMALL(IF(AI3:AI32>0,AI3:AI32),ROW(1:32))

    commit using CTRL+SHIFT+ENTER

    you now need to adjust the other formulas to use the rows 3 to 32

  22. #22
    Forum Contributor
    Join Date
    07-05-2012
    Location
    Stockholm
    MS-Off Ver
    Excel 2010
    Posts
    162

    Re: Chart showing date and names on a time axis

    Hi,

    Ok, with your guidance I got the range to work and "bubbles" to appear in the charts. On the first chart however I can't for my life get the bubbles to display the correct data label, Name 1-30. Instead it's showing just a number value (x or y value).
    What am I missing?

    Also, when I filter (as you can see in the attachment, some rows get an invalid reference (column AJ & AK). Why is that?

    Cheers!
    Attached Files Attached Files

  23. #23
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,430

    Re: Chart showing date and names on a time axis

    You did not adjust all the formula in column AK correctly.

    The data labels are linked to cells, rather than displaying x, y, category or series name.
    You may need to relink the labels to cells. There is a series, called TEXT, that is purely for displaying data labels. Do not put data labels on the other data series as they do not contain the correct data label information.

    Free chart label addin
    http://www.appspro.com/Utilities/ChartLabeler.htm

  24. #24
    Forum Contributor
    Join Date
    07-05-2012
    Location
    Stockholm
    MS-Off Ver
    Excel 2010
    Posts
    162

    Re: Chart showing date and names on a time axis

    Hi, I think the formulas are correct now. However something still seems to be wrong though. For instance, "Name 18"(column B) is on the same row showing "Name 30" in column AK. And the rows below are just showing "NUM!

    I'm afraid I don't understand how to do with the labels. Terribly sorry.

    KR
    Attached Files Attached Files

  25. #25
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,430

    Re: Chart showing date and names on a time axis

    The #NUM! are to be expected.

    When you link data labels to cells the linking does not take into account filtered/hidden rows.
    http://www.andypope.info/ngs/ng57.htm

    So the formula generates the correct labels starting in row 3. This could mean some/all of the labels are actually hidden in the table.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1