0

I am plotting a line graph in Excel and my data is as follows:

Line graph data img

As you can see there are rows with the same name (an example is highlighted). How do I combine these into the same series? So I will see a line on my graph for each row, but the values of the duplicate rows will be combined, so each point has two values.

Note, I wish to do this in order to avoid any slopes between changes in my graph. What I want is:

Graph with no gradient example img

If there is a better way to do this please let me know!

Update: Scatter graph with duplicate values still showing slopes:

Scatter graph img

1
  • your sample data starts from x=6, but the chart starts from 1, how? also there are a lot of other lines which disturb reading. Can you please clean up your example? Commented Jan 9, 2017 at 10:56

1 Answer 1

0

You've a wrong approach for that, Excel doesn't combine data like that.

What you can do instead: create one series of data including two x points where you want to have the break, and include both y values.

Than insert a scatter plot with straight line, it'll look similar to this:

enter image description here

4
  • Thanks for your answer. I have added extra columns now where the duplicates need to be but I am still seeing a gradient rather than a vertical. My chart type is 'Scatter with Straight Lines'. Example image added to question - note the red line still has slopes.
    – petehallw
    Commented Jan 9, 2017 at 10:41
  • Your series apparently does not use specific X values. Instead it is using the index of each point (1, 2, 3, etc.) for X values. You need to specify X values for each series. Commented Jan 12, 2017 at 2:43
  • @JonPeltier: is this a comment to the question or to the answer? The example in the answer DOES USE specific x values. Commented Jan 12, 2017 at 7:55
  • Sorry for the confusion. I was replying to the OP's comment on your answer, which does in fact use specific X values. But the OP tried your approach and still did not get the chart he wanted, because I think he still does not use specifically defined X values. Commented Jan 12, 2017 at 18:01

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .