hi try with plyr library and function ddply Andrija
On 30 Aug 2012 12:58, "Sam Steingold" <s...@gnu.org> wrote: > > Is there a way for an apply-type function to return a data frame? > the closest thing I think of is > > foo <- as.data.frame(sapply(...)) > names(foo) <- c(....) > > is there a more "elegant" way? > Thanks! > -- > Sam Steingold (http://sds.podval.org/) on Ubuntu 12.04 (precise) X 11.0.11103000 > http://www.childpsy.net/ http://palestinefacts.org http://dhimmi.com > http://honestreporting.com http://ffii.org http://mideasttruth.com > Lisp: it's here to save your butt. > > ______________________________________________ > 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. [[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.