On Fri, Jul 25, 2008 at 8:50 PM, hadley wickham <[EMAIL PROTECTED]> wrote: > On Fri, Jul 25, 2008 at 9:49 AM, baptiste auguie <[EMAIL PROTECTED]> wrote: >> Dear list, >> >> >> I'm trying to use the reshape package to perform a merging operation on a >> list of data.frames as illustrated below, >> >>> a <- 1:10 >>> example <- list( data.frame(a=a, b=sin(a)), data.frame(a=a, b=cos(a)) ) >>> >>> melt(example, id = a) > > You want: > > melt(example, id = "a") > > i.e. the id argument is a character or numeric vector specifying which > variables to use as id variables. Your call would be equivalent to > > melt(example, id = 1:10) > > which clearly is incorrect for your example.
I've just noticed that there's also a bug in the released version (fixed in my development version) which means that the id argument to melt.list() is not being passed on to the individual melt.data.frame()s Hadley -- http://had.co.nz/ ______________________________________________ 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.