Hello everyone, What is the most efficient & simpliest way to convert all components of a list to separate columns in a matrix?
Is there an easy way to programmatically "pad" the length of the resulting shorter character vectors so that they can be easily combined into a data frame? I have the following code that stores the 2 compoents (of differing lengths) in the same character vector: more<-c('R is a free software environment for statistical computing', 'It compiles and runs on a wide variety of UNIX platforms') result<-strsplit(more,' ') result mode(result) class(result) sapply(result,length) result2<-unlist(result) result2 mode(result2) class(result2) Thank you, Dan [[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.