Re: [R] Combine two columns

From: Gabor Grothendieck <ggrothendieck_at_gmail.com>
Date: Fri, 07 Mar 2008 16:18:50 -0500

Depending on your purpose you might want to look at ?interaction or its synonym : (i.e. a colon)

On Fri, Mar 7, 2008 at 4:09 PM, <amarkey_at_uiuc.edu> wrote:
> Is there a way to combine two columns within a data frame?
>
> Example data:
>
> id snp AL1 AL2
> 1500 30 A B
> 1510 30 A A
> 1520 30 A B
>
> This is what I would like:
>
> indv snp AL1AL2
> 1500 30 AB
> 1510 30 AA
> 1520 30 AB
>
> Any help is greatly appreciated.
>
> Alysta
>
> ______________________________________________
> R-help_at_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_at_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. Received on Fri 07 Mar 2008 - 21:21:06 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Fri 07 Mar 2008 - 23:30:20 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive