For the Histogram Method, clean_lc was originally a FORTRAN 77 program developed by Steve Snowden and K.D. Kuntz in 2005-6. The task espfilt was originally a perl script that operated on an input event list then used a system call to envoke clean_lc. The perl script and the F77 program have been converted entirely to FORTRAN 95, accessing XMM-Newton datasets via the DAL.
Clean_lc's purpose is to clean a light curve by creating a histogram of rate values from the light curve, finding the most likely value assuming that to be similar to the mean of the quiescent rate, then fitting a Gaussian to a small window around that value in the histogram to determine the true mean and dispersion of the quiescent background rate. The program then excludes time intervals with rate higher than a multiple of the dispersion above the mean quiescent background and excludes good regions shorter than some limit.