[R] Combining columns
oluola2011 at yahoo.com
Mon Nov 21 23:58:36 CET 2016
Thank you Jim and Don.
On Monday, November 21, 2016 4:54 PM, Jim Lemon <drjimlemon at gmail.com> wrote:
If you always have only one non-NA value in the first three columns:
On Tue, Nov 22, 2016 at 8:26 AM, Olu Ola via R-help
<r-help at r-project.org> wrote:
> Hello,I have the following data
> | colA | colB | colC | colD |
> | NA | pumpkin | NA | Pumpkin |
> | Cassava | NA | NA | Cassava |
> | yam | NA | NA | yam |
> | NA | Cherry | NA | Cherry |
> | NA | NA | Pepper | Pepper |
> | NA | NA | Mango | Mango |
> | maize | NA | NA | maize |
> All I want to do is to combine the first three columns in order to obtain the fourth column.
> A way forward will be greatly appreciated.
> [[alternative HTML version deleted]]
> R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
[[alternative HTML version deleted]]
More information about the R-help