Skip to content
Prev 165477 / 398506 Next

filling values in a vector using smaller vector

I believe the following does what is wanted:

desired <- large
desired[large] <- small


Patrick Burns
patrick at burns-stat.com
+44 (0)20 8525 0696
http://www.burns-stat.com
(home of S Poetry and "A Guide for the Unwilling S User")
Milton Huang wrote: