Re: [R] add column with values found in another data frame

2012-01-15 Thread jdog76
Thanks so much Jorge and Pete ! Pete Brecknock wrote > > > frame2$age = frame1[match(frame2$ID, frame1$ID),"age"] > > This match function was exactly what I needed to know! -- View this message in context: http://r.789695.n4.nabble.com/add-column-with-values-found-in-another-data-frame-tp4

[R] add column with values found in another data frame

2012-01-14 Thread jdog76
I am positive this problem has a very simple solution, but I have been unable to find it, so I am asking for your help. I need to know how to look something up in one data frame and add it as a column in another. If I have a data frame that looks like this: > frame1 ID score test age 1 Guy1