Cosmogenic neutrinos as a probe of the transition from Galactic to extragalactic cosmic rays