One way:

as.vector(t(cbind(ColA, ColB)))

Ross, Stephanie wrote:
Hello,

I have a general formatting question. I have two columns of data:

ColA <- c("m", "m", "m", "m")
ColB<- c("d","d","d","d")

And I would like to reorder them into a new column that looks like this:

ColC<- c("m","d","m","d","m","d","m","d")

Thank you!

Stephanie

________________________________
PHRI DISCLAIMER
This information is directed in confidence solely to the person named above and 
may not otherwise be distributed, copied or disclosed. Therefore, this 
information should be considered strictly confidential. If you have received 
this email in error, please notify the sender immediately via a return email 
for further direction. Thank you for your assistance.

        [[alternative HTML version deleted]]

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to