How to Make Pie Chart by Count of Values in Excel

In this article, we are going to show you 2 methods to make a Pie Chart by the count of values in Excel.


How to Make Pie Chart by Count of Values in Excel: 2 Handy Approaches

To demonstrate the methods, we have picked a dataset with 3 columns: “Company“, “Product“, and “Sold (Qty)“. First, we will use two functions to count the values and then PivotTable to achieve the target of this article. Moreover, here is the snapshot of our dataset and the Pie Chart.

Excel Pie Chart Count of Values


1. Applying Combined Functions to Make Pie Chart by Count of Values

In this section, we will use the UNIQUE and COUNTIF functions to count the values of the Product column. Then, from the Insert Charts command, we plot the Pie Chart by the count of values in Excel. Remember, the UNIQUE function is available in Office 365 only. Without further ado, let us show you the guide.

Steps:

  • To begin with, we have formatted the cell range B19:C23.
  • Next, type the following formula in cell B20.

=UNIQUE(C5:C17)

  • This formula finds the unique values from the selected cell range.

Excel Pie Chart Count of Values 2

  • Then, press ENTER.
  • Afterward, select the cell range C20:C23 and type this formula.

=COUNTIF($C$5:$C$17,B20)

  • This formula finds the number of occurrences of the unique values in the cell range from the dataset. Moreover, it is mandatory to use the absolute cell reference in this case.

Excel Pie Chart Count of Values 3

  • After that, press CTRL+ENTER.
  • So, this will AutoFill the formula to the cells.
  • Now, we will insert the Pie Chart.
  • Therefore, select the cell range B20:C23.
  • Then, from the Insert tab → Insert Pie or Doughnut Chart → select Pie.

Excel Pie Chart Count of Values 4

  • Hence, this will create a basic Pie Chart and we will modify it next.

Excel Pie Chart Count of Values 5

  • Firstly, select the graph.
  • Secondly, from the Chart ElementsLegend → select Right. This will move the Legend to the right side of the graph.

Excel Pie Chart Count of Values 6

  • Thirdly, from the Data Labels → select “More Options…”.

Excel Pie Chart Count of Values 7

  • Then, the Format Data Labels box will appear on the right side of our Workbook.
  • After that, select Category Name, and Legend Key from the Label Contains section.
  • Next, select Outside End from the Label Position section.

Excel Pie Chart Count of Values 8

  • By doing so, the Pie Chart will look like this.

Excel Pie Chart Count of Values 9

  • Then, we added a Chart Title, increased font size, and moved the Data Labels a bit to show the Leader Lines.
  • Finally, this is the output of our first method.

Excel Pie Chart Count of Values 10

Read More: How to Show Percentage and Value in Excel Pie Chart


2. Using PivotTable to Make Pie Chart by Count of Values in Excel

For the last method, we will find the unique values and their counts by using the PivotTable feature.

Steps:

  • At first, select the cell range C4:D17 and from the Insert tab → select PivotTable.
  • So, the “PivotTable from table or rangedialog box will pop up.
  • Next, select Existing Worksheet and cell B19 as the output location.
  • Then, press OK.

Excel Pie Chart Count of Values 11

  • Thus, it brings a blank PivotTable.

Excel Pie Chart Count of Values 12

  • Next, from the PivotTable Fields window, drag the Product field to the Rows and Values areas.
  • After that, it will show us the unique values and their counts.

PivotTable Fields

  • Then, select the PivotTable, and from the PivotTable Analyze tab → select PivotChart.

PivotChart

  • So, the Insert Chart window will appear.
  • Then, select Pie and press OK.

Pie Chart Insert

  • Consequently, it will show the basic Pie Chart with the count of values.

Basic Pie Chart

  • Lastly, as shown in method 1, we have modified the graph and the final step should look like this.

Final Output of Method 2

Read More: How to Show Percentage in Excel Pie Chart


Practice Section

We have added a practice dataset for each method in the Excel file. Therefore, you can follow along with our methods easily.

Practice Dataset


Download Practice Workbook


Conclusion

We have shown you 2 handy approaches to how to make a Pie Chart by the count of values in Excel. If you face any problems regarding these methods or have any feedback for me, feel free to comment below. Moreover, you can visit our site ExcelDemy for more Excel-related articles. Thanks for reading, keep excelling!


Related Articles


<< Go Back To Excel Pie ChartExcel ChartsLearn Excel

Get FREE Advanced Excel Exercises with Solutions!
Rafiul Haq
Rafiul Haq

Rafiul Haq worked as an Excel and VBA Content Developer in Exceldemy for over two years and published almost 200 articles for the website. He is passionate about exploring new aspects of Excel and VBA. He received his Bachelor of Science in Mechanical and Production Engineering (MPE) from the Islamic University of Technology. Rafiul furthered his education by obtaining an MBA in Finance from the Institute of Business Administration (IBA) at the University of Dhaka. Apart from creating... Read Full Bio

We will be happy to hear your thoughts

Leave a reply

Advanced Excel Exercises with Solutions PDF

 

 

ExcelDemy
Logo