I am a supporter of
St. Joseph's hospice.
 If you find this site useful or if it helped you, consider a small donation to
St. Joseph's, please.

Information on
St. Joseph's

JustGiving - Sponsor me now!

 

CumNorm

A modified CumNorm function of Graeme West's version I show below. Please notice that his article is directed at Excel 2003 © (from Excel 2007 © on you will not need this anymore) - it is a bit unfortunate that he did not point this out.

Function Cumnorm(x As Double) As Double
'See Graeme West: Better Approximations to Cumulative Normal Functions, 22 Sep 2006
Dim XAbs As Double, Build As Double, Exponential As Double
    XAbs = Abs(x)
    If XAbs > 37# Then
        Cumnorm = 0#
    Else
        Exponential = Exp(-XAbs ^ 2# / 2#)
        If XAbs < 7.07106781186547 Then
            Build = 3.52624965998911E-02 * XAbs + 0.700383064443688
            Build = Build * XAbs + 6.37396220353165
            Build = Build * XAbs + 33.912866078383
            Build = Build * XAbs + 112.079291497871
            Build = Build * XAbs + 221.213596169931
            Build = Build * XAbs + 220.206867912376
            Cumnorm = Exponential * Build
            Build = 8.83883476483184E-02 * XAbs + 1.75566716318264
            Build = Build * XAbs + 16.064177579207
            Build = Build * XAbs + 86.7807322029461
            Build = Build * XAbs + 296.564248779674
            Build = Build * XAbs + 637.333633378831
            Build = Build * XAbs + 793.826512519948
            Build = Build * XAbs + 440.413735824752
            Cumnorm = Cumnorm / Build
        Else
            Build = XAbs + 0.65
            Build = XAbs + 4# / Build
            Build = XAbs + 3# / Build
            Build = XAbs + 2# / Build
            Build = XAbs + 1# / Build
            Cumnorm = Exponential / Build / 2.506628274631
        End If
    End If
    If x > 0# Then Cumnorm = 1# - Cumnorm
End Function

Sulprobil   Get it done   Contact   Disclaimer   Impressum   Download