FREQUENCY in ONLYOFFICE Spreadsheet Editor
Count values in upper-bound bins with the extra overflow result, exact boundary examples, sorted-bin behavior and source-specific text-bin handling.
Verification status: See the evidence and test scope described in this guide. How formula examples are checked
Quick answer: For values 0,5,10,10,15,20,25 and bins 10,20, =FREQUENCY(A1:A7,C1:C2) has independently expected vertical counts 4,2,1, including the overflow bin above 20.
Availability and evidence scope
- Introduced: Original introduction release is not established by the checked sources.
- Available: Listed in current unversioned ONLYOFFICE help, checked October 18, 2026.
- Implementation inspected: Official SDKJS v10.0.0.169, commit
3679e0375a758d7dc59d31337a45461be3525ed8. The snapshot does not prove identical behavior in every installed editor. - Retired or deprecated: These sources do not establish retirement or formal deprecation.
- Testing: Numerical examples are independent mathematical expectations, and implementation discrepancies are labeled source predictions. No ONLYOFFICE application or calculation-engine execution was performed.
The examples use English function names and commas. Use your locale’s argument separator if different. Retain full precision in formulas; round only the displayed result. Nested output grids describe source-derived array contents. Native spill placement, obstruction errors, array-entry shortcuts and recalculation behavior have not been tested in the application. Reserve a separate output area and follow the array-formula entry method supported by your installed editor; do not assume a particular keyboard shortcut or automatic spill behavior.
Syntax and what a bin means
=FREQUENCY(data_array, bins_array)
Both arguments are required. data_array contains observations and bins_array contains upper boundaries. For an ordinary ascending numeric bin list with m entries, the result is a vertical array with m+1 counts. The extra count is for observations above the largest boundary.
The first bin contains values less than or equal to the first boundary. Each later ordinary bin is greater than the preceding boundary and less than or equal to its own boundary. The final overflow bin is strictly greater than the last boundary. These are counts, not percentages, densities or cumulative totals.
The inspected implementation sorts the bin boundaries internally. Keep your worksheet bins sorted anyway: output labels must describe the sorted boundaries, not the original order of an unsorted input range. A blank or text-containing bin range needs additional care because the source treats those element types differently.
Step-by-step: include boundary values and overflow
- Enter
0,5,10,10,15,20,25vertically in A1:A7. - Enter
10in C1 and20in C2. - Reserve three vertical output positions, even though the bin list has only two entries.
- Evaluate
=FREQUENCY(A1:A7,C1:C2)with the supported array-formula workflow.
| Output position | Interval | Observations | Independent count |
|---|---|---|---|
| 1 | x≤10 | 0, 5, 10, 10 | 4 |
| 2 | 10<x≤20 | 15, 20 | 2 |
| 3 | x>20 | 25 | 1 |
The counts total 7, matching the seven numeric observations. Both occurrences of 10 are counted. Values equal to a boundary belong to that boundary’s bin, not the one after it. Zero is a numeric observation and is included in the first bin; a physically blank cell is different.
The independent check simply assigns each observation to the first boundary greater than or equal to it, with overflow when no boundary qualifies. It does not execute the ONLYOFFICE function or claim a particular spill display.
Advanced example: turn counts into proportions
For this dataset, divide the counts by 7 to obtain relative frequencies 4/7, 2/7 and 1/7. Their total is 1. If you calculate the denominator from a worksheet, ensure it counts the same numeric data that FREQUENCY includes, rather than counting text labels or blank-looking strings as observations.
For a histogram, label the last row explicitly as “above 20.” Omitting the overflow row makes the shown counts total only 6 and can conceal out-of-range data. If bins have unequal widths, relative frequency per bin is not a density; dividing by bin width is a separate operation. The first and last open-ended intervals need a defined plotting convention rather than an invented finite width.
If bins are changed to 20 then 10, the inspected source sorts them and still predicts counts 4,2,1. Labels copied directly from the unsorted cells would be misleading. If bins are 10,20,20, the duplicate boundary creates an empty interval 20<x≤20, so the expected counts are 4,2,0,1. Deliberately deduplicate boundaries unless that empty category is wanted.
Numeric data versus nonnumeric bins
Inside a range or array, the inspected data loop includes numeric elements and skips text, Boolean and empty elements. An error element is returned rather than silently skipped. The bin loop behaves differently: numeric boundaries are kept, text and Boolean bin elements are converted to zero, and empty elements are skipped. Error bins propagate.
For the worked numeric observations, bins consisting of text label and numeric 10 are source-predicted to become boundaries 0 and 10, giving counts 1,3,3. This is not a recommendation to use text bins. Store descriptive labels in a separate column and keep the actual boundary range numeric.
A cell containing a formula returning "" is text rather than a genuinely empty element; in the inspected bin-range loop it therefore contributes a zero boundary. A genuinely blank bin is skipped, potentially shortening the result relative to the selected range’s visible height. The familiar “number of selected bins plus one” rule is reliable for the clean numeric list used above, not every mixed-type range.
Errors and scope
The top-level wrapper rejects an empty argument with internal wrong_value_type, conventionally #VALUE!, and propagates existing errors. Single-cell references are converted numerically before being wrapped as an array, so not every scalar or single-cell text case follows the same path as text embedded in a multi-cell range. Prefer clean numeric ranges for reproducibility.
The output is vertical even when numeric bins are arranged horizontally. Count entries are nonnegative integers, but the implementation’s array-entry and worksheet-placement behavior is not verified here. Ensure the complete result, including overflow, is available before summarizing it. Large data ranges and unusual three-dimensional references require separate performance and compatibility checks.
Compatibility and related functions
Recalculate representative formulas when moving a workbook between editors. Matching names do not guarantee identical argument coercion, array behavior, numerical precision or error handling. These source-derived examples do not establish automatic spill behavior or a general import/export guarantee.
Official references
- ONLYOFFICE FREQUENCY help, checked October 18, 2026.
- Official SDKJS implementation, 7210–7364, tag v10.0.0.169 and exact commit above.