I'm on MS Excel 365, trying to plot a simple plot, but after inserting a total of only 8 numbers as a data source for the plot (by selecting the appropriate cells), I get 50 entries on the x axis...
I tried to format the x axis to exactly 8 entries by editing the data source of the x axis to ={"1","1.5","2","2.5","3","3.5","4"}, but then it just leaves the other 42 blank.
This is how it looks like before I Formatted The X Axis:

And this is what happens after I formated the x axis to ={"1","1.5","2","2.5","3","3.5","4"}:

I also tried formatting the axis to a text axis instead of Auto, but it doesn't let me edit the text on the axis for some reason.. Anyway, I don't want to go this path, I prefer to understand why the straight forward way didn't work and how to resolve it.
Appreciate any help, thanks!
Added information following a comment:
My data are numbers on my sheet, I selected 8 cells, each of them is a number from 61.77 to 84.36 as you can see in the attached screenshots. I didn't have numbers for the X axis and for some reason Excel decided that the X axis will be 50 entries of numbers from 1 to 50, so I tried to edit that through Select Data->Edit Horizontal Axis:
- in this screenshot you can see where I've edited this - I tried writing 1,1.5,2,2.5,3,3.5,4 and hit enter and then instead of replacing 50 entries with these 8, it replaced the first 8 as intended but left 42 blank ones as I mentioned before and you can see here:
.
Then I opened this editing window again and saw that Excel wrote it as {"1","1.5","2","2.5","3","3.5","4"}, meaning a set of strings instead of the list of numbers I wrote before (I didn't write it like this before).
Hope this clarifies the confusion I made.
Thank you!!
Another update - I tried creating a set of values on seperate cells according to a suggestion here, unfortunately the problems remains:
. I suspected it's not the problem since I've created another chart the same way I created this one and the X axis was fine (Excel created 4 X axis entries according to the 4 Y Axis entries I selected from 4 different cells - as oppose to this chart where I selected 8 cells and got 50 X axis entries for some reason...)
To make a scatter (XY) chart you need numerical data for both axes. And the number of data should be equal. In your example you have 8 values for
yan only 7 values forx.Maybe this is a source of your problem?
If you mark only
yvalues you get a chart withxvalues equal to 1, 2, 3, ...