I need to make a new column (col.4) that is populated with values from an existing column (col.2) chosen as a condition of the original neighboring column (col.1) and the same values in a new (longer) neighbor column (col.3). How can this be achieved? The data would look something like this:
col.1 col.2 col.3 col.4
1 A 1 A
2 B 2 B
3 C 2 B
4 D 3 C
- - 1 A
- - 4 D
- - 3 C
- - 4 D