Cumulative Frequency on Excel: Step-by-Step Guide
In this article
Cumulative frequency in Excel is a running total of frequencies: each row shows the count of values up to that point, which is the basis for ogive charts and percentile estimates. You can build it with one simple formula next to your frequency column, then optionally chart it. All you need is a list of values or a frequency table already in a worksheet.
What You'll Need
- Excel on desktop (Windows or Mac) or Excel for the web; the steps below use the desktop version
- Your raw data in a single column, or an existing frequency table
- Basic familiarity with typing formulas into cells
Step-by-Step
The process has two parts: building the frequency table, then adding the cumulative column. If you already have frequencies, skip to step 5.
- Set up class intervals. In a new area of the worksheet, list your class upper boundaries in one column (for example, in column D starting at D2). Each boundary is the highest value included in that class, such as 10, 20, 30 and so on.
- Count the frequency of each class. In the cell next to the first boundary (E2), enter a COUNTIFS formula that counts values greater than the previous boundary and less than or equal to the current one. For data in A2:A101 and boundaries starting at 10, type:
=COUNTIFS($A$2:$A$101,">"&(D1),$A$2:$A$101,"<="&D2). If there is no boundary in D1, the first class can simply use=COUNTIFS($A$2:$A$101,"<="&D2). - Copy the formula down. Drag the fill handle from E2 down alongside all your boundaries so every class has a frequency.
- Check the total. In the cell below the frequencies, enter
=SUM(E2:E10)(adjust the range to your data). It should equal the number of data points. If it does not, a boundary is missing or overlapping. - Add the cumulative frequency column. In F2, next to the first frequency, type
=E2and press Enter. The first cumulative value always equals the first frequency. - Enter the running-total formula. In F3, type
=F2+E3and press Enter. This adds the current frequency to the total above it. - Fill down. Drag the fill handle from F3 down to the last class. The final value in column F should equal your total from step 4; if it does, the column is correct.
- Optional: add relative cumulative frequency. In G2, type
=F2/$E$11(using the cell holding your total) and format the column as percentages via Home > Number > Percentage. - Optional: chart it. Select the boundaries and the cumulative column, then go to Insert > Charts and choose a Scatter with Straight Lines chart (or a Line chart) to produce an ogive. Put the upper boundaries on the horizontal axis and cumulative frequency on the vertical axis.
Exact menu labels can differ slightly between Excel versions and platforms, but the Insert tab and chart options described above are consistent across current desktop versions.
Common Mistakes
- Mixing up lower and upper boundaries. Cumulative frequency is read against the upper boundary of each class. Using lower boundaries shifts the whole table and gives wrong percentile answers.
- Forgetting dollar signs in COUNTIFS. Without absolute references like $A$2:$A$101, copying the formula down shifts the data range and produces counts from the wrong cells.
- Overlapping or gapped classes. A value of exactly 20 must belong to only one class. Be consistent: for example, classes of the form greater than 10 and up to 20.
- Starting the cumulative column with the running-total formula. The first cell should simply equal the first frequency; using =F1+E2 in the first row adds a blank or header and breaks the total.
- Not verifying the final total. The last cumulative value must equal the count of your data. Skipping this check hides errors.
Tips
- Sort your raw data first (Data > Sort) if you plan to check the frequencies manually against the list.
- If your data is already a frequency table, you only need steps 5 to 7; the COUNTIFS steps are for raw data.
- To estimate a median or percentile from the table, find the target value (half the total for the median) in the cumulative column, then read across to the class boundary and interpolate if you need a more precise estimate.
- Give your columns clear headers such as Upper Bound, Frequency, Cumulative Frequency so charts pick up sensible axis titles automatically.
- The SUM version of the running total,
=SUM($E$2:E2)in F2 filled down, gives the same result and can be easier to copy in one go.
Troubleshooting
- #NAME? or #VALUE! errors: check that COUNTIFS is spelled correctly, ranges are the same size, and boundary cells contain numbers rather than text.
- Frequencies come out as zero: confirm the boundary logic is right (greater than the previous, less than or equal to the current) and that your data range actually covers the data. Press Ctrl+Down from the first data cell to find where the data really ends.
- The total does not match your data count: compare SUM of frequencies with COUNT of the raw data. A mismatch usually means overlapping boundaries or a class you forgot to include.
- Chart looks wrong or lines dip: cumulative frequency must never decrease. If it does, one row's formula references the wrong cell; re-check that each formula adds the frequency on its own row.
- Excel for the web differences: the formulas work identically; only the chart insertion interface looks slightly different, with charts under the Insert tab as well.
Frequently Asked Questions
What is the difference between frequency and cumulative frequency?
Frequency counts how many values fall in one class; cumulative frequency counts how many values fall in that class and all classes below it, so it keeps increasing down the table.
Can I make a cumulative frequency graph in Excel?
Yes. Select the class boundaries and cumulative values, then insert a Scatter with Straight Lines chart. This produces the classic ogive shape.
Is there a built-in cumulative frequency function in Excel?
No. There is no dedicated function, but a running total formula or expanding SUM such as =SUM($E$2:E2) achieves it in one step.
How do I find the median from a cumulative frequency table?
Take half of the total frequency, find where the cumulative column first reaches that value, and read the corresponding class boundary. Interpolate within the class for a more precise estimate.
Does this work in Google Sheets too?
Yes. COUNTIFS, SUM and expanding ranges behave the same way, and you can insert a similar line or scatter chart, though menu labels differ.