changed getMidpointStats to re-use calculatePeak. need to reconsider if need this function at all. the error comes up in cases where the compressed data set the peak is no longer at midpoint. cant always assume midpoint is peak