read.table - R: How to merge objects to a table? -


how can create table out of objects? imagine following 3 objects:

green<-10 red<- 12 blue<-5 

how can combine them table follows:

table1<-read.table(header = true, text =  "green red blue 10 12 5") 

any ideas? thank much!

one option objects in list , convert data.frame.

data.frame(mget(c('green', 'red', 'blue'))) 

Comments