Create a chart based on multiple datas in the same row

Copper Contributor

Dear Community,

My question is (I believe) very simple to answer, but somehow being pretty new to Excel I cannot figure out how to solve it. 

I want to create a (pie) chart based on multiple datas that are all in the same row, but different columns.

 

Screenshot 2024-04-28 at 16.16.56.png

 

As you can see in the picture, I want to create a pie chart that shows me how my expenses, which are divided in 7 categories, are actually split. I tried to create it selecting the name of the category and its expense by holding cmd/crtl, but when I create the chart it only considers the "Food" category and its price. As you can see from the columns highlighted in green, I am actually selecting all those cells, but somehow it does not work.

I overcame the problem once by listing the categories and the prices in the same columns, but in different rows and it worked. But I cannot believe that it's not possible if the datas are on the same row, there must be a way, right?!

I want to mention that I have a Mac and use Excel online, in case this influences it. 

I look forward to hearing from some expert 😉

Thank you in advance

5 Replies

@SatoshiBtc 

I'm afraid you'll have to reorganize the data, with the categories below each other in one column and the corresponding values in the next column.

@SatoshiBtc This is not Mac related. You need to structure the data correctly, but not how you have in your screenshot. Example attached.

 

Alright, thank you very much for the quick response and the attachment.

@SatoshiBtc 

It would be interesting to know whether the attached workbook functions on either of your platforms!

I have used 365 functions within locally-named formulas to extract the category and associated values for plotting.  Putting such definitions into the SERIES chart function is not a good experience.  There are reserved names you can't use and when the chart engine errors it just sits there sulking and doing nothing.

 

image.png

The formulas themselves use array shaping functions to extract every third value from the data.