Patent ID: 6917830

Claim:
A method for operating a cardiac rhythm management device, comprising: sampling an electrogram signal from a sensing channel of the device to obtain a series of samples, where each sample can be designated by X[n] with n an integer; determining whether each sample represents a local peak or not, wherein a sample X[n] is a local peak if its amplitude is either: 1) greater than the amplitude of the preceding sample X[n−1] by a specified threshold value δ 1 and also greater than the amplitude of the subsequent sample X[n+1] by the specified threshold δ 2 , or 2) less than the amplitude of the preceding sample X[n−1] by a specified threshold δ 3 and also less than the amplitude of the subsequent sample X[n+1] by the specified threshold δ 4 ; computing a local peak density in a predetermined number of consecutive samples; computing a noise flag as either set or cleared in accordance with the computed local peak density, wherein the noise flag is set if the local peak density exceeds a first threshold value; and, estimating a noise level in the electrogram signal by computing a noise statistic from a series of samples when the noise flag is set.