A statistics-based threshold for the RMS-energy oscillation detector. (June 2021)