         }
         self.channels = channels
         
+        // setup stats
+        var statInput = [SummaryStat]()
+        var statOutput = [SummaryStat]()
+        for var i = 0; i < self.detectors.count; ++i {
+            statInput.append(SummaryStat(withStat: StatMax()))
+            statOutput.append(SummaryStat(withStat: StatMax()))
+        }
+        self.statInput = statInput
+        self.statOutput = statOutput
+        
         // setup input and output devices
         interfaceInput = AudioInputInterface(deviceID: deviceInput.deviceID)
         interfaceOutput = AudioOutputInterface(deviceID: deviceOutput.deviceID)

        }
    }
    
    func getOutputForChannel(channel: Int) -> Float? {
        // valid channel
        guard channel < channels.count else { return nil }
        

//

import Cocoa
import Accelerate
import AudioToolbox

struct ProcessorEntry {
