These are required functions from Lieb's et al. spike detection toolbox. "findlambda" is not required.