Stddevp

The MDX Stddevp function for Essbase calculates the standard deviation of the specified set. This function assumes that the set represents the entire population. If you want to calculate based a sample of a population, use Stddev.

Standard deviation is a measure of how widely values are dispersed from their mean (average).

Syntax

Stddevp ( set [,numeric_value_expression [,IncludeEmpty] ])

Parameters

set

A valid MDX set specification.

numeric_value_expression

A numeric value or an expression that returns a numeric value (see MDX Grammar Rules).

IncludeEmpty

Use this keyword if you want to include in the calculation any tuples with #MISSING values. Otherwise, they are omitted by default.

Example

The following example, based on Sample Basic, calculates the standard deviation (based on the entire population) of the January sales values for all products sold in New York.

WITH MEMBER [Measures].[Std Deviation]
AS
 'StddevP(
    Crossjoin(
     {[Product].Children}, {[Measures].[Sales]}
    )
  )
 ' 
SELECT
 {[Scenario].[Actual],[Scenario].[Budget]}
ON COLUMNS, 
   {Crossjoin(
     {[Measures].[Sales]},{[Product].Children}
    ),
    Crossjoin(
     {[Measures].[Sales], [Measures].[Std Deviation]},
     {[Product]}
    )}
ON ROWS
FROM 
 Sample.Basic
WHERE
 ([Year].[Jan], [Market].[New York])

This query returns the following grid:

Table 4-127 Output Grid from MDX Example

(axis) Actual Budget
(Sales, 100) 678 640
(Sales, 200) 551 530
(Sales, 300) 663 510
(Sales, 400) 587 620
(Sales, Diet) #Missing #Missing
(Sales, Product) 2479 2300
(Std Deviation, Product) 52.59 55.9

See Also

Stddev