Data driven approach for the measurement of Be-10/Be-9 in cosmic rays with magnetic spectrometers