Modified so only points between yMin and yMax are moving