+ Reply to Thread
Results 1 to 8 of 8

Insert Graphs [that automatically update based on variables]

  1. #1
    Forum Contributor
    Join Date
    08-25-2013
    Location
    Virginia, USA
    MS-Off Ver
    Excel 2013
    Posts
    205

    Insert Graphs [that automatically update based on variables]

    In the attached example, I'm looking to create the two graphs depicted in the file (the one in tab 1b and the one in tab 2b) that automatically update based upon the variables listed in tabs 1a and 2a. I don't know how to create those graphs. Please let me know if you have any questions.
    Attached Files Attached Files
    Last edited by 6StringJazzer; 09-21-2022 at 10:40 AM. Reason: better titles please

  2. #2
    Forum Expert
    Join Date
    06-05-2017
    Location
    Brazil
    MS-Off Ver
    Microsoft 365 Version 2404
    Posts
    1,259

    Re: Insert Graphs [that automatically update based on variables]

    Hello, quibilty. I hope it is not too late for this.

    I did it with helper columns, the first starting in A26, with this formula, copied down to A100:
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    Next in B26, with this formula, copied down to B100:
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    Then I use the Name Manager in the Excel Formula ribbon to create dynamic named ranges to select data for the graph.
    For example, for the X-axis I created the range named Index, with this formula:
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    To view those named ranges, right-click on the graph, then click Select data.

    Please run some test and let us know how it goes.

    Good luck!
    Attached Files Attached Files

  3. #3
    Forum Contributor
    Join Date
    08-25-2013
    Location
    Virginia, USA
    MS-Off Ver
    Excel 2013
    Posts
    205

    Re: Insert Graphs [that automatically update based on variables]

    Thanks a lot for this, this is really great. I do have some feedback/questions:

    1) For tab 1a's graph, is there a way to make it so that the "MIN" and "MAX" level (the black lines) appear at (lowest value - 1) and (highest value + 1)?
    2) I don't see a graph for 2a. Did you include a graph on tab 2a that reflects the data in tab 2, or am I just missing it?

    Thank you so much for your help.

  4. #4
    Forum Expert
    Join Date
    06-05-2017
    Location
    Brazil
    MS-Off Ver
    Microsoft 365 Version 2404
    Posts
    1,259

    Re: Insert Graphs [that automatically update based on variables]

    Hi. You're welcome.

    I have added columns for max and min values, so as to add them to your graph.
    But I made them (lowest value - 0.5) and highest value + 0.5, so the lines show closer to actual values in the graph.
    Also, I have added a graph to the other tab, no helper columns required.
    Attached Files Attached Files

  5. #5
    Forum Contributor
    Join Date
    08-25-2013
    Location
    Virginia, USA
    MS-Off Ver
    Excel 2013
    Posts
    205

    Re: Insert Graphs [that automatically update based on variables]

    Estevaoba, thank you again. We're soooo close! A couple things.

    1) Would you please re-create those charts in tab "Sheet 2" in the attached file?
    2) Would you please set the min and max levels (the black lines) for the graph with 64 plot points to the values that are at F38 and M38?

    This way I should be able to copy/paste the graphs onto the original document and use the search/replace feature to make the formula work on the original document.

    Thank you.
    Attached Files Attached Files

  6. #6
    Forum Expert
    Join Date
    06-05-2017
    Location
    Brazil
    MS-Off Ver
    Microsoft 365 Version 2404
    Posts
    1,259

    Re: Insert Graphs [that automatically update based on variables]

    I took the text values from the range rows and used extraction formulas to create min/max rows for the first graph.
    Please check attachment.
    Attached Files Attached Files

  7. #7
    Forum Contributor
    Join Date
    08-25-2013
    Location
    Virginia, USA
    MS-Off Ver
    Excel 2013
    Posts
    205

    Re: Insert Graphs [that automatically update based on variables]

    I'm not sure what happened, but the chart on the left has changed so that it's now incorrect. The min and max values of points 2, 3, 14, and 15 are zero when they should be (point 2; 23.3 min, 28.3 max), (point 3; 21.5 min and 26.5), (point 14; 21.5 min and 26.5), and (point 15; 23.3 min, 28.3 max). Are you able to change that?

    Also, do you think you can add a line that shows the "average" value in the form of a red line on the graph?

    Thanks a lot! This will be so helpful once it's done.

  8. #8
    Forum Expert
    Join Date
    06-05-2017
    Location
    Brazil
    MS-Off Ver
    Microsoft 365 Version 2404
    Posts
    1,259

    Re: Insert Graphs [that automatically update based on variables]

    I had the same error in those four points, because the decimal separator in my Excel language (Portuguese) is a comma. But I thought there would be no error for you, since a period is used as decimal separator in English.

    =VALUE(LEFT(C13,SEARCH(" -",C13)-1))
    The formula above, for the minimum values, should result 23.3 for you in C15, but for some reason it results an error.
    So I added the SUBSTITUTE function, just like I did it here, as in the formula below.

    =VALUE(SUBSTITUTE(LEFT(C13,SEARCH(" -",C13)-1),".",","))

    Also, I have added a new helper column for the average line in the second graph.

    Sorry for the late reply. I've been taking some training the last couple days. Tomorrw I'll go to sea and Internet service onboard is not very good, so I may not be able to check this thread in the next four weeks, but I'll try.
    I hope this will help you with your project.

    Have a blessed day.
    Attached Files Attached Files

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Replies: 1
    Last Post: 10-24-2014, 12:20 AM
  2. multiple graphs on one screen and moving graphs
    By mufan in forum Excel Charting & Pivots
    Replies: 1
    Last Post: 02-12-2014, 04:49 PM
  3. Replies: 4
    Last Post: 07-15-2013, 05:42 AM
  4. [SOLVED] Macro to insert row and copy cells and update graphs, and recommend VB Introduction Book
    By gjrr4x1 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 01-03-2013, 12:36 PM
  5. Macro to insert 2 graphs from seperate excel tabs into a single word document
    By rpt21 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 04-06-2010, 04:59 PM
  6. How do I insert standard deviation to my graphs in excel?
    By sanfrancisco_cat in forum Excel General
    Replies: 0
    Last Post: 03-21-2006, 03:10 PM
  7. Automatic Graphs/ Dynamic Graphs
    By DanielWalters6 in forum Excel Charting & Pivots
    Replies: 1
    Last Post: 01-24-2006, 05:35 PM

Tags for this Thread

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