Replace beamMS with applyBeam