    PROGRAM g01dbfe

!      G01DBF Example Program Text

!      Mark 23 Release. NAG Copyright 2011.

!      .. Use Statements ..
       USE nag_library, ONLY : g01dbf, nag_wp
!      .. Implicit None Statement ..
       IMPLICIT NONE
!      .. Parameters ..
       INTEGER, PARAMETER              :: nout = 6
!      .. Local Scalars ..
       INTEGER                         :: ifail, n
!      .. Local Arrays ..
       REAL (KIND=nag_wp), ALLOCATABLE :: pp(:)
!      .. Executable Statements ..
       WRITE (nout,*) 'G01DBF Example Program Results'
       WRITE (nout,*)

!      Set the problem size
       n = 10

       ALLOCATE (pp(n))

!      Calculate the normal scores
       ifail = 0
       CALL g01dbf(n,pp,ifail)

!      Display results
       WRITE (nout,99999) 'Sample size = ', n
       WRITE (nout,*) 'Normal scores'
       WRITE (nout,99998) pp(1:n)

99999  FORMAT (1X,A,I2)
99998  FORMAT (10X,5F12.4)
    END PROGRAM g01dbfe
