Yesterday, we have seen a beautiful example of how showing details (like distribution) on-demand can increase the effectiveness of your reports. Today, we will learn how to do the same in Excel.
Before jumping in to the tutorial,
In this post, I have explained one technique of using charts + VBA to dynamically show details for a selected item. There are 4 other ways to do the same – viz. using cell comments, pivot charts, group / un-group feature and hyperlinks. I have made a 45 minute video training explaining all the 5 techniques in detail. Plus there an Excel workbook with all the techniques demoed. You can get both of these for $17.
Click here to get the video training – Showing on-demand details in Excel
How does the on-demand details chart work – demo:
This is a replica of yesterday’s chart from Amazon. When you click on any cell inside the Items + Rating table, the corresponding items review break-up is shown in the chart aside.

Creating this chart in Excel – Step-by-step Instruction
So you are ready to learn how to do this chart? Great, grab a cup of coffee or tea and get started.
1. Understanding the data
This is how I have setup the source data for the chart. It has 3 columns – Item name, Reviewer ID and Rating. Each item has several ratings from several different reviewers. And our goal is to summarize all these ratings.

All this data is in the range Table1. We will use structured references [what are they?] in formulas to keep them readable.
2. Setting up the Item & Rating Table
The first step is to show a table with all the products we sell and their corresponding average rating. We will then add the circle indicators at the end to visually show the rating.

Calculating the averages using AVERAGEIF() formula:
The formula is quite simple. Assuming the product names are in C5:C13,
We just write =AVERAGEIF(Table1[Item],C5,Table1[Rating]) for first product’s average. Fill the rest by dragging the formula down.
Displaying Circles:
There are no star symbols in the default fonts. But we have circles – a full circle, an empty circle and a donut to indicate half-circle. These symbols are available in Wingdings 2 font. We will use an incell chart to display the circles. Assuming the rating is 2.83, we need to print 2 full circles, one donut and 2 empty circles. [related: inserting symbols in to Excel workbooks]
The formula is quite simple. Since the ratings are in D5:D13, the formula becomes,
=REPT(fullCircleSymbol,INT(D5)) & REPT(donutSymbol,(INT(D5)<>D5)+0) & REPT(emptyCircleSymbol,INT(5-D5))
Naming this grid
Now that we are done with the rating grid, let us name it – rngReviews.
3. Finding out which cell is selected
Now comes the macro part.
Before jumping in to the code, take a sip of that coffee. It is getting cold.
When a user selects any cell inside rngReviews, we need to findout which product it is so that we can load corresponding details.
The macro logic is quite straight forward.
- On Worksheet_SelectionChange, check if the ActiveCell overlaps with rngReviews
- If so,
- findout the relative row number of ActiveCell with respect to topmost row in rngReviews (ie the position of selected cell inside rngReviews)
- Put this value in to a cell on worksheet – say E28
The macro code can be found in the downloaded workbook. Here is an image of macro code.
4. Using the macro output to drive…,
We need to use the value E28 to do 2 things.
- Highlight the corresponding row in the rngReviews using conditional formatting.
- Findout the corresponding product using INDEX formula.
I am leaving both of these to your imagination.
5. Calculating Product – Rating Breakup
In order to show details for the product, we must calculate the corresponding breakup of ratings (ie how many 1 star, 2 star … 5 star reviews the product got).
I am leaving the formulas for this to your imagination. But when you are done, make sure your output looks like this:

(hint: use COUNTIFS formula).
6. Create a Chart to show Rating Break-up
This is the last one before we put everything together. Just follow below 5 steps.
- Select the 3 columns – Rating type, number of reviews, total reviews and create a bar chart (not stacked bar chart). In my workbook, this data is in the range C29:E34 in the sheet “Rating Summary”.
- Reverse the order of categories as Excel shows them upside down. For this select the vertical axis and hit CTRL+1 (or go to axis options from right click menu). Here check the “Show categories in reverse order” option. Also remove the chart legend.
- Set both series of the chart such that they completely overlap each other [image]. Adjust the gap width to 50%. Also, adjust the order of the series from Chart’s source data options [image].
- Remove grid lines, axis line and horizontal axis. Format the chart colors to your pink and translucent green (really!).
- Re-size the chart, add title, add labels, remove border. You need to use dynamic titles.

7. Put everything together
Now is the time to put everything together and test. Move the chart close to the rating table. Test it by clicking on any value inside table.
You can also do some colorful formatting if you prefer.

Finish the coffee and show-off the chart to a colleague or boss. Bask in glory.
Download Example Workbook – On-demand Details in Excel
Click here to download the workbook with this example. Play with it to understand how this chart works.
Note: You must enable macros to use the file.
Note2: If the file does not open on double-click, just open Excel (2007 or above) and drag the file inside to Excel.
Learn this + 4 other techniques using Video Training,
In this post, I have explained one technique of using charts + VBA to dynamically show details for a selected item. There are 4 other ways to do the same – viz. using cell comments, pivot charts, group / un-group feature and hyperlinks. I have made a 45 minute video training explaining all the 5 techniques in detail. Plus there an Excel workbook with all the techniques demoed. You can get both of these for $17.
Click here to get the video training – Showing on-demand details in Excel
How do you like this chart?
Ever since I learned this technique from a good friend, I have been using it in dashboards & complex models to make them more user friendly.
What about you? Did you like this technique? Where are you planning to use it? Please share your views & ideas using comments.
More Resources to One-up your Chart Awesomeness
Want more, here is more:

















30 Responses to “Great News: Chandoo becomes MVP”
Congratulations! It's well deserved. 🙂
This is amazing. Hearty congratulations and a rocking new year ahead!!!
Congrats! I have learnt alot from your site... and the most important is learning how to achieve the most with the simplest concepts.
Thanks for the excel calendar. Is it possible to get a simple big fonted calendar printable on an A4 size paper without any distracive notes or visuals? BTW, I have already signed up for your newsletter. With warm regards and
Gratefully yours
50+ year old CHarish.
Hey Chandoo,
Great to hear that. Congratulations! The best new year gift, I would say. Keep it up, u've been doing extraordinary work for the excel users community.
Regards,
Pankaj Verma
Congrats dude... fantastic news!
congratulations! your site is great, this is well deserved
Rich
I recently found your site, I visit many. The tips that you provide are in the top 1% of all the sites I visit. Keep on Excelling.
Arnold
South Africa
Congratulations, Chandoo! That's a great way to start the year and make the PHD even better.
Congratulations, Chandoo.
Your site is one of most useful on the net. Happy new year and lot of ideas you will present for us.
Congrats.
Just read your name in an email from Abhishek. Well deserved.
Congratulations, and Happy New Year.
Greetings from Rio de Janeiro my friend! You trully deserve it!
Nive way to start 2009! Keep up the good work!
FC
That was quite forseeable , so you have now really got your PhD in excel.
Anyways Chandoo you have made excel a real Fun doo
I will like you to write some more on INDEX and MATCH function in near future.
@Hey Chandoo ! Congrates....
Ab to treat mangta hai !
Well deserved Chandoo!!
Congrat's!! Very well deserved 🙂
i always browsed mr.excel and used to see MVP writtne below names of people who used to solve queries in excel forum there......i just used to admire as to what they have special in them that they are MVP......
but now i got my answer...............u deserve it man..........
@All: thanks everyone 🙂
Congratulations Chandoo, nice job!
Chandoo,
A well deserved recognition and a good start to the New Year. Continue your good work.
Subbu
Many Congratulations.
You deserve a Ph.D. 🙂
congrats.....
Congrats dude. Rock on!
[...] charting community in 2007 and has been growing strongly ever since. In year 2009, I have received the MVP award from Microsoft. Just few days back I have become a dad [...]
Respected sir,
I am impressed!.... Good job done.. Keep it up...
Sir, How to be a MVP certified person. What level of knowledge is required for it? send me links if possible.
Please reply...
Regards,
Dipak Khalasi.
Dipak -
The first thing you need to cultivate is the ability to search the web effectively. You could start by Googling "Microsoft MVP".
[...] boy and girl which has been made hectic and incredibly fun ever since to their life.He has been awarded MVP status in 2009 by Microsoft(and renewed in 2010,2011 & 2012).His MVP profile is here.If you want to contact him direct then [...]
Congrats Chandoo!!
[…] Chandoo becomes MVP […]