Re: [R] match a complete data.frame

2013-02-12 Thread Mat
i found a way :-)

data-merge(data,project,by.x=PJ_ID,by.y=PROJ_ID,all.x=TRUE)

perhaps this can help someone

Mat



--
View this message in context: 
http://r.789695.n4.nabble.com/match-a-complete-data-frame-tp4658250p4658252.html
Sent from the R help mailing list archive at Nabble.com.

__
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.


Re: [R] match a complete data.frame

2013-02-12 Thread David Winsemius

On Feb 12, 2013, at 5:10 AM, Mat wrote:

 hello togehter,
 
 how can i match a complete data.frame to another one?
 
 I know i can match one column with that code:
 
 A-match(data$PJ_ID,project$PROJ_ID)
 data$Name-proj$Name[A]

How about:

data - data[  match(data$PJ_ID,project$PROJ_ID) , ]

(Untested in the absence of data ... or 'data'.




 but how can i match the total data.frame from project to data?
 indivduel matching for each column is not very productive
 
-- 

David Winsemius
Alameda, CA, USA

__
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.