A 89Y NMR study of Pr- and Nd-doped YBa2Cu3O7