Vendor/phpspreadsheet/phpoffice/phpspreadsheet/src/PhpSpreadsheet/Calculation/Statistical.php
public static function NORMDIST($value, $mean, $stdDev, $cumulative)
    {
        $value = Functions::flattenSingleValue($value);
        $mean = Functions::flattenSingleValue($mean);
        $stdDev = Functions::flattenSingleValue($stdDev);

        if ((is_numeric($value)) && (is_numeric($mean)) && (is_numeric($stdDev))) {
            if ($stdDev < 0) {
                return Functions::NAN();
            }
            if ((is_numeric($cumulative)) || (is_bool($cumulative))) {
                if ($cumulative) {
                    return 0.5 * (1 + Engineering::erfVal(($value - $mean) / ($stdDev * sqrt(2))));
                }

                return (1 / (self::SQRT2PI * $stdDev)) * exp(0 - (pow($value - $mean, 2) / (2 * ($stdDev * $stdDev))));
            }
        }

        return Functions::VALUE();
    }
public static function NORMDIST($value, $mean, $stdDev, $cumulative)
    {
        $value = Functions::flattenSingleValue($value);
        $mean = Functions::flattenSingleValue($mean);
        $stdDev = Functions::flattenSingleValue($stdDev);

        if ((is_numeric($value)) && (is_numeric($mean)) && (is_numeric($stdDev))) {
            if ($stdDev < 0) {
                return Functions::NAN();
            }
            if ((is_numeric($cumulative)) || (is_bool($cumulative))) {
                if ($cumulative) {
                    return 0.5 * (1 + Engineering::erfVal(($value - $mean) / ($stdDev * sqrt(2))));
                }

                return (1 / (self::SQRT2PI * $stdDev)) * exp(0 - (pow($value - $mean, 2) / (2 * ($stdDev * $stdDev))));
            }
        }

        return Functions::VALUE();
    }
public static function NORMDIST ( $ value , $ mean , $ stdDev , $ cumulative ) { $ value = Functions :: flattenSingleValue ( $ value ) ; $ mean = Functions :: flattenSingleValue ( $ mean ) ; $ stdDev = Functions :: flattenSingleValue ( $ stdDev ) ; if ( ( is_numeric ( $ value ) ) && ( is_numeric ( $ mean ) ) && ( is_numeric ( $ stdDev ) ) ) { if ( $ stdDev < 0 ) { return Functions :: NAN ( ) ; } if ( ( is_numeric ( $ cumulative ) ) || ( is_bool ( $ cumulative ) ) ) { if ( $ cumulative ) { return 0.5 * ( 1 + Engineering :: erfVal ( ( $ value - $ mean ) / ( $ stdDev * sqrt ( 2 ) ) ) ) ; } return ( 1 / ( self :: SQRT2PI * $ stdDev ) ) * exp ( 0 - ( pow ( $ value - $ mean , 2 ) / ( 2 * ( $ stdDev * $ stdDev ) ) ) ) ; } } return Functions :: VALUE ( ) ; }
NORMDIST.

Returns the normal distribution for the specified mean and standard deviation. This
function has a very wide range of applications in statistics, including hypothesis
testing.

@param float $value
@param float $mean Mean Value
@param float $stdDev Standard Deviation
@param bool $cumulative

@return float
NORMDIST .