the data.frame is like:
|col_1|
|------|
|A |
|B |
|B |
|A |
|A |
The expected output should be:
|col_A |col_B |
|---------|-------|
|A |NA |
|NA |B |
|A |NA |
|NA |B |
|A |NA |
|A |NA |
I can do this manually in excel but is there a concise way in R to get this done?