Skip to main content

NORMAL_CDF

Description​

Computes the Cumulative distribution function (CDF) of the normal distribution at value x.

  • Returns NULL when the standard deviation of the normal distribution is less than or equal to 0.

Syntax​

NORMAL_CDF(<mean>, <sd>, <x>)

Parameters​

ParameterDescription
<mean>The mean of the normal distribution
<sd>The standard deviation of the normal distribution
<x>The value to be evaluated

Return Value​

Return the Cumulative distribution Function (CDF) for a Normal random variable at a value x.

  • Return NULL when standard deviation of the normal distribution is less than or equal to 0.

Examples​

select normal_cdf(10, 9, 10);
+-----------------------------------------------------------------------+
| normal_cdf(cast(10 as DOUBLE), cast(9 as DOUBLE), cast(10 as DOUBLE)) |
+-----------------------------------------------------------------------+
| 0.5 |
+-----------------------------------------------------------------------+
select NORMAL_CDF(10, 0, 10);
+-----------------------------------------------------------------------+
| normal_cdf(cast(10 as DOUBLE), cast(0 as DOUBLE), cast(10 as DOUBLE)) |
+-----------------------------------------------------------------------+
| NULL |
+-----------------------------------------------------------------------+