I have 2 columns in a data frame with 15.000 entries.

```
col1   col2
mike   anna
eve    charly
george mike
jenn   george

```

I would like to find out, which entries in Col1 are a certain amount higher than in Col2.

I already have a solution where I loop thru each entry in Col1 and check it's position in Col2, but with 15.000 in takes ages:

```
for(i in 1:nrow(df)){  
    myposinCol2 <- grep(df[i,1], df[,2])
    if(myposinCol2[1] > (i + 500)){ #take it }
 }

```

Could someone point me in a direction to improve this?

Thx
Joerg