Added code for moving-average-based hypothesis (hypo3).