Lets say i have a data.frame looking like this:
structure(list(HUGO.Int1 = c("AATF", "AATF", "AATF", "ABHD16A",
"ABHD16A", "ABHD16A"), Mut.Int1 = c(0, 0, 0, 0, 0, 0), HUGO.Int2 = c("DAPK3",
"PAWR", "CHEK1", "RNF5", "ATP5G3", "HM13"), Mut.Int2 = c(0, 0,
0, 0, 0, 0)), .Names = c("HUGO.Int1", "Mut.Int1", "HUGO.Int2",
"Mut.Int2"), row.names = c(12223L, 15033L, 31655L, 11280L, 11463L,
14106L), class = "data.frame")
and i want HUGO.Int2 and Mut.Int2 to be below HUGO.Int1 and Mut.Int1
I’ve tried
data.frame(rbind(c(plots$HUGO.Int1, plots$Mut.Int1),
c(plots$HUGO.Int2, plots$Mut.Int2)))
But then I only get 2 columns back, Hugo.int1 and Mut.int1. I’d like to know how to properly paste the 3rd and 4rd column below the 1st and 2nd.
The problem is that you’ve stuck
rbindin there, sort of at random. This is what your attempt probably should have looked like: