Creating diagonal matrix (diag) from Excel sheet

It's hard to tell why you're failing from the provided information. Can you please turn this into a reproducible example? If you don't know how, here's a helpful post:

I'm not sure I understand exactly what do you mean by this:

Do you mean you're not getting the elements of columns 2-389 in row 265 using this? Do you fail only for the 265^{th} row, or also for some other rows?

And, what is USEEIOv1_1_Matrices_B? Is it the complete data? And, what is Rnox.diag? You haven't defined it yet.