DSTDEVP Function (OpenOffice Calc)
Use DSTDEVP in Apache OpenOffice Calc to calculate population standard deviation for the records selected by criteria. Includes criteria examples, expected results and compatibility notes.
Verification status: Official documentation referenced; example outcomes independently reasoned or arithmetically checked where stated. Not executed in OpenOffice Calc. How formula examples are checked
Quick answer
Use DSTDEVP in Apache OpenOffice Calc to calculate population standard deviation for the records selected by criteria. With the data and Team 1 criteria below, =DSTDEVP($A$1:$F$7;"Score";H1:H2) has an independently checked expected result of 14.790199458 score points.
Choose DSTDEVP when the selected records constitute the complete group you intend to describe. For example, the four registered Team 1 observations may be the entire reporting group, rather than a sample used to estimate a broader process. The official Apache OpenOffice Calc reference documents this database function. Here, “database” means a rectangular worksheet range with a header row; it does not require a database server.
Exact syntax and parameters
=DSTDEVP(database;field;criteria)
Database: include the headers as well as the data, for example $A$1:$F$7. One row represents one record. Do not start at row 2 and accidentally treat the first record as the header.
Field: identify the column to calculate, such as "Score". A column number is counted from the left edge of the database, starting at 1; it is not a worksheet column letter. The field being calculated can differ from the field used to filter records.
Criteria: supply a separate cell range containing matching column headings and the conditions below them. Conditions on the same row mean AND; separate condition rows mean OR. A record satisfying more than one alternative is still one selected record. The examples always provide all three arguments and do not depend on omitted-field behaviour.
Apache’s English Calc Help uses semicolons. These examples follow that notation, not Excel’s comma-separated examples. Localized names and separators may differ; follow your installed Function Wizard or formula editor. The examples deliberately use numeric Team/Class codes to avoid assuming identical text-pattern settings between programs.
Practice data and layout
Open a blank worksheet. Enter the six headers ID, Team, Class, Score, Factor, Note in A1:F1, then enter the records below in A2:F7. F3 must be truly empty: do not type the words “leave empty.” Place criteria to the right of the database and results in column K, so no result overwrites an input.
| Row | A: ID | B: Team | C: Class | D: Score | E: Factor | F: Note |
|---|---|---|---|---|---|---|
| 2 | 101 | 1 | 1 | 10 | 2 | Ready |
| 3 | 102 | 1 | 2 | 20 | 3 | leave empty |
| 4 | 103 | 2 | 1 | 30 | 4 | Hold |
| 5 | 104 | 1 | 1 | 40 | 5 | Ready |
| 6 | 105 | 2 | 2 | 50 | 6 | Ready |
| 7 | 106 | 1 | 2 | 0 | 1 | Hold |
Download the input CSV. This CSV contains the six-column input table only, not formulas or prefilled criteria. Import at A1 and keep the empty Note field empty. The same fixture is used in the companion program guide to make cross-software comparisons reproducible.
Worked examples: one condition, AND and OR
Example 1 — select Team 1
Put Team in H1 and the number 1 in H2. In K2 enter:
=DSTDEVP($A$1:$F$7;"Score";H1:H2)
Expected result: 14.790199458. The selected IDs are 101, 102, 104, 106. The selected Team 1 scores have mean 17.5 and squared deviations totalling 875. Treating these four scores as the entire population gives variance 875 / 4 = 218.75 and population standard deviation approximately 14.790199458 points.
Example 2 — Team 1 AND Class 1
Enter H5=Team, I5=Class, H6=1, I6=1. Both tests are in the same criteria row, so a record must pass both. Enter in K6:
=DSTDEVP($A$1:$F$7;"Score";H5:I6)
Expected result: 15. Only IDs 101 and 104 match. Compare those two source records with the result, rather than counting every Team 1 record or every Class 1 record independently.
Example 3 — Team 2 OR Score at least 40
Enter H9=Team, I9=Score, H10=2, leave I10 and H11 empty, and type >=40 in I11. These are two alternative criteria rows. In K10 enter:
=DSTDEVP($A$1:$F$7;"Score";H9:I11)
Expected result: 8.164965809. The selected IDs are 103, 104 and 105. Record 105 meets both alternatives but is included only once. This is why adding two separate aggregates can give a different answer when their conditions overlap.
Advanced example — two bounds on the same field
Use the header Score twice, in H14 and I14. Type >=20 in H15 and <=40 in I15. Repeated headings let you express a lower and upper bound on one field within the same AND row. In K15 enter:
=DSTDEVP($A$1:$F$7;"Score";H14:I15)
Expected result: 8.164965809. The selected IDs are 102, 103 and 104. The bounds are inclusive. Putting the two bounds on different rows would express OR and would select a different set of records.
Interpret the result correctly
The letter P describes the denominator and interpretation, not the size of the data range. Restricting a database with criteria does not automatically make it a sample. Decide which population the result refers to and state that in the report.
For the same four scores, DSTDEV uses n - 1 and gives about 17.078251277 instead. Both computations are internally consistent but answer different statistical questions. At least one numeric observation is needed for the population formula; a single numeric observation has zero spread mathematically.
Troubleshooting and scope
If a result looks wrong, check the selected record IDs before changing the arithmetic. A heading typed differently from the database header, a criteria range lacking its header, or a condition placed on the wrong row changes the selection. Keep criteria ranges tight: accidentally including an entirely empty alternatives row can undermine the intended restriction.
Inspect numeric inputs as numbers, not imported text with currency symbols or hidden spaces. These examples use valid numbers and one genuinely empty Note cell. They do not establish how every blank, formula-generated empty string, boolean, error cell or numeric-looking text is coerced in every release.
Apache Calc’s help explicitly notes that calculation settings affect identical-entry searches and includes regular-expression guidance. Do not copy Excel wildcard assumptions into a text-criteria worksheet without checking those settings. For DCOUNT, Apache documents a nonempty field parameter; the examples use a header rather than its special field-zero option. For large or changing data, expand the database range deliberately to include new rows. Absolute references such as $A$1:$F$7 prevent copying from shifting the range, but they do not make the range grow automatically.
Compatibility and related functions
The Gnumeric DSTDEVP guide uses the same input data and record-selection examples. The two official references document the same broad purpose and three-part database/field/criteria structure. That is not proof of identical error tokens, text matching, numeric coercion or file-format round trips. Start with these ordinary numeric cases, then test your actual workbook in each destination program.
Related Apache OpenOffice Calc functions: DSTDEV, DVARP, DCOUNT, DAVERAGE. Choose a different aggregate when the question changes rather than interpreting every numeric output as a total or a count.
How this guide was checked
Official references reviewed on 2026-10-12: Apache OpenOffice Calc database-function documentation and the companion program’s documentation. Argument order, header-based selection and the function’s purpose were checked against those references. The worked dataset, selected IDs and arithmetic are original examples, independently evaluated with a small Python model.
No native application run: these are expected results, not outputs observed in an installed Apache OpenOffice Calc application. No claim is made about the earliest release supporting the function or every platform. The documentation checked is English desktop-function documentation, not a mobile compatibility guarantee. Example-check record · Editorial standards.