[R] Table Intersection

rantree gabriel.wajnberg at hotmail.com
Wed Jan 18 16:25:47 CET 2012


I've got two tables....

first one(table1):

ID     chrom        start         end

Ex1       2                152          180
Ex2       10              2000          2220
Ex3       15              3000           4000

second one ( table2):

chrom      location        name
2                     160              Alv
2                    190               GNN
2                    100               ARg
10                  210               GGG                
15                 3200             ADSA

 What I have to do is to put name column in table1  when  the location of
the name  is between the start and end ....and chrom must be the same....it
will be this the result:

ID     chrom        start         end               name
Ex1       2                152          180               Alv
Ex2       10              2000          2220         GGG
Ex3       15              3000           4000         ADSA


How can i do this ????

--
View this message in context: http://r.789695.n4.nabble.com/Table-Intersection-tp4306968p4306968.html
Sent from the R help mailing list archive at Nabble.com.



More information about the R-help mailing list