1

I have following values that I would like to display on the X axis of my chart:

0,1,2,3,4,5,6,7,8,9,10,10,10,9,8,7,6,5,4,3,2,1,0

But my chart is displaying the values as 0,1,2,3,4,5,6,7,8,9,10,11,12...

Is there a way to use the values as single entries instead of using them as values?

Thanks!

user2452250
  • 123
  • 1
  • 5
  • How are these values stored? Are they 1 entry per cell? – Dave May 19 '14 at 07:39
  • Apparently you want to interpret your numbers as a text. Have you tried formatting them as a text (prefixing values with ' or by using [TEXT function](http://office.microsoft.com/en-001/excel-help/text-function-HP010062580.aspx))? – Bulwersator May 19 '14 at 07:09
  • I cant, because i need them for some math. I tried to set them as text in the chart with no result. – user2452250 May 19 '14 at 07:16
  • @user2452250 What about using TEXT function - http://office.microsoft.com/en-001/excel-help/text-function-HP010062580.aspx ? – Bulwersator May 19 '14 at 07:24
  • Are you running any macro's/vba on the work sheet – Dave May 19 '14 at 11:36

1 Answers1

1

You've not said which version of Excel you're using, but it should be similar for most recent versions I think:

  • Choose Insert -> Charts -> Insert Line Chart -> Line from the ribbon to insert a blank line graph.
  • With the graph selected, click the Select Data option from the ribbon
  • With the cursor in the Chart data range text box, highlight the cells containing your Y values
  • On the right-hand side, under Horizontal (Category) Axis Labels, click Edit
  • Select the range containing your X axis values and press OK
  • Press OK to close the chart editor dialog.

enter image description here

James P
  • 11,206
  • 5
  • 43
  • 50