fixed errors, added main method
created DomainPredictor to call PeakDetector iteratively