fixed nearest date to point calculation