removed peak detection from graphUtils as it is now a seperate function