private void checkForPeakY(double y) {
		if (isUpPeakY) {
			if (y < lastY) {
				peakY = lastY;
				isUpPeakY = false;
			}
		} else {
			if (y > lastY) {
				peakY = lastY;
				isUpPeakY = true;
			}
		}

		lastY = y;
	}