      SUBROUTINE GAUDIF(XM1,EB1,XM2,EB2,Q) ! BERG JUNE 15 1999.
C COMPARISION OF TWO MEANS: GAUSSIAN DIFFERENCE TEST.
C INPUT: TWO GAUSSIAN DATA POINTS, MEAN VALUES AND ERROR BARS.
C OUPUT: LIKELIHOOD Q  THAT THE DISCREPANCY IS DUE TO CHANCE.
      include '../../Libs/Fortran/implicit.sta'
      include '../../Libs/Fortran/constants.par'
      SIGMA=SQRT(EB1**2+EB2**2)
      XX=+ABS(XM1-XM2)/(SIGMA*SQRT(TWO))
      Q=ONE-ERROR_F(XX)
      RETURN
      END