Changing graph axes using named range

S

simon.stewart

Hi,
I have a large table of data, each column is defined as a range. What
I would like to do is use the drop down list (using data validation)
where each option in the list is a named range, to change the graph's
x and y axes.
For example, if I were to select the named range for column C as my x
axis (using the drop down list) and column F as my Y axis, I would
like the graph to automatically plot this without going into the
=SERIES(<legend entry>,<X Values>,<Y Values>,<PlotOrder>)
formula and changing the named range manually. I have tried to
reference the cells in this formula where I have written the name of
the range's in them but it doesn't work. Can anybody help?
Thanks a lot!
Simon
 
B

Bernard Liengme

Here is a start.I have:
1) text "X","Y","Z" in A1:C1 (no quotes,of course,anywhere)
2) In G1 the text "Y"
3) In D1 the formula =G1 (it shows "Y")
4) In A:C2 the numbers for x-values, y-values, z-values
5) I have named B2:B10 as Y and C2:C10 as Z
6) In D2 the formula =INDIRECT($G$2) and this is copied down the column
7) A chart with x-axis A2:A10 and y-axis D2:D10
The chart plots the Y values
When I type "Z" in G1 the chart plots the Z values
best wishes
 
S

simon.stewart

With a few adjustments that seems to do the trick thanks!
Is there a way of making the named ranges more dynamic? I know of the
counta formula so it goes to the end of the data when you add more,
the only problem for me being that my columns are filled with if
formulas that are taken into account using the counta formula. Is
there an alternative?
Thanks,
Simon
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top