> On Mar 9, 2015, at 1:53 PM, Duncan Murdoch <murdoch.dun...@gmail.com> wrote: > > On 09/03/2015 1:40 PM, Kristina Loderer wrote: >> Dear R community, >> >> to combine data sets of hierarchical, nested nature (i.e., data sets >> linked by, for example, the variable "study ID" and then also by >> "outcome_variable_1" and "outcome_variable_2") I can use the match files >> command in SPSS. What is the equivalent command / function in R? Is it >> the merge function, or the match function? The more I read, the more >> confused I become.. >> > > I don't know SPSS at all, so I can't help you. If nobody else does, you > might try putting together a tiny example in R showing what you're starting > with, and what you want to produce. From what you wrote, I'd guess merge(), > not match(), but you might really be asking for something completely > different. > > Duncan Murdoch
Based upon the info here: http://www.ats.ucla.edu/stat/spss/modules/merge.htm I would go with ?merge, since the desired functionality appears to be a relational join operation. Regards, Marc Schwartz ______________________________________________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see 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.