I have a set of data which is similar to the following:

Groceries     5.00
Groceries    14.75
Groceries     6.37
Dinner Out   43.50
Dinner Out   15.00

I'd like to be able to use this data to create some graphs, such that (in this case) I'd have two categories, and the graph displays the sum, namely Groceries -> 26.12, Dinner Out -> 58.50. etc etc.

Is this possible to do automatically, without me collapsing these rows into one sum per category?


In Excel you would use a Pivot Table and in Google Spreadsheets you would need to use a Gadget. I tried it with the "Table by Google" gadget and it was straightforward though, I've used pivot tables before so it was very familiar.

Here is a more complicated example using a gadget I couldn't find.

  • Great thanks - I found it under the table section of the gadgets – Noel M Aug 31 '10 at 21:21

In new Google Sheets a chart can be drawn from a pivot table, no gadget necessary:

WA6107 first example

Alternatively, check Aggregate column A:

WA6107 second example

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.