Assuming a vector (or matrix) ids
> 1 2 3 3 2
Assume that each of these identifiers corresponds to a numerical value stored in another vector
14 33 25
I would like to replace identifiers with their corresponding value in order to build the following vector
14 33 25 25 33
There should be an easy way to achieve this without resorting to cycles, but my brain is currently not coping with me, and I could not find anything in the documentation. Any ideas?
Kena source
share