DVARP function
Calculates the variance of a column for the records that match the criteria, treating them as the entire population.
Available in All versions of Excel, including Microsoft 365 and Excel for the web
In every Excel versionWorks in Google Sheets
Syntax
DVARP(database, field, criteria)| Argument | What it means | |
|---|---|---|
database | Required | The list including its header row. |
field | Required | The numeric column to analyse. |
criteria | Required | The criteria range. |
Returns: The population variance (divides by n) of the matching values.
How DVARP works
DVARP returns the variance of the matching records when those records are the whole population of interest. It divides the sum of squared deviations by n, like VAR.P, so the result is a little smaller than DVAR on the same data. Use it for complete groups — all products in a category, all staff in a department — rather than samples.
As with the other D-functions, the records are selected by a criteria range on the sheet, which means the same formula can answer the question for any department or threshold simply by changing a cell. Taking the square root of the result gives DSTDEVP.
Examples
1Variance of the whole Sales team's salaries
| A | B | C | D | E | F | |
|---|---|---|---|---|---|---|
| 1 | Dept | Name | Years | Salary | ||
| 2 | Sales | Ana | 3 | 42000 | 10722222.22 | |
| 3 | IT | Ben | 7 | 58000 | ||
| 4 | Sales | Carla | 5 | 46500 | ||
| 5 | IT | Dev | 2 | 49000 | ||
| 6 | HR | Eli | 9 | 51000 | ||
| 7 | Sales | Fay | 1 | 38500 | ||
| 8 | ||||||
| 9 | Dept | |||||
| 10 | Sales |
Result: 10722222.22
The same squared deviations as in the DVAR example, divided by 3 instead of 2: 10722222.22 (two decimals).
2All staff with at least 3 years
| A | B | C | D | E | F | |
|---|---|---|---|---|---|---|
| 1 | Dept | Name | Years | Salary | ||
| 2 | Sales | Ana | 3 | 42000 | 34921875 | |
| 3 | IT | Ben | 7 | 58000 | ||
| 4 | Sales | Carla | 5 | 46500 | ||
| 5 | IT | Dev | 2 | 49000 | ||
| 6 | HR | Eli | 9 | 51000 | ||
| 7 | Sales | Fay | 1 | 38500 | ||
| 8 | ||||||
| 9 | Years | |||||
| 10 | >=3 |
Result: 34921875
Four qualifying salaries, divided by 4: the population variance is 34921875.
Common errors and how to fix them
| Error | Why it happens | Fix |
|---|---|---|
#DIV/0! | No matching numeric values. | Check the criteria. |
#VALUE! | The field name is not in the list. | Use the exact header or a column number. |
Tips
- DVARP = DVAR × (n − 1) / n, where n is the number of matching values; with many records the two are almost equal.
- Variance is in squared units; take SQRT of it (or use DSTDEVP) for a figure in the original units.
Google Sheets
DVARP also exists in Google Sheets and works the same way for everyday use, so the examples above work there too.
DVARP in other languages
In a non-English version of Excel the function has a local name. Excel translates formulas automatically when a file is opened in another language.
| Language | Function name |
|---|---|
| Czech | DVAR |
| Danish | DVARIANSP |
| Dutch | DBVARP |
| Finnish | TVARIANSSIP |
| French | BDVARP |
| German | DBVARIANZEN |
| Hungarian | AB.VAR2 |
| Italian | DB.VAR.POP |
| Norwegian (Bokmål) | DVARIANSP |
| Polish | BD.WARIANCJA.POPUL |
| Portuguese (Brazil) | BDVARP |
| Portuguese (Portugal) | BDVARP |
| Russian | БДДИСПП |
| Spanish | BDVARP |
| Swedish | DVARIANSP |
| Turkish | VSEÇVARS |