# Delete rows that exist in another data frame in Julia?

**URL:** https://discourse.julialang.org/t/delete-rows-that-exist-in-another-data-frame-in-julia/24645
**Category:** New to Julia
**Tags:** question
**Created:** [May 27, 2019, 8:52am UTC](https://discourse.julialang.org/t/delete-rows-that-exist-in-another-data-frame-in-julia/24645 "2019-05-27T08:52:31Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![Luigi\_Marongiu](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/luigi_marongiu/32/7909_2.png) [@Luigi\_Marongiu](https://discourse.julialang.org/u/Luigi_Marongiu)
#### Post date: [May 27, 2019, 8:52am UTC](https://discourse.julialang.org/t/delete-rows-that-exist-in-another-data-frame-in-julia/24645/1 "2019-05-27T08:52:31Z")

</div>

Dear all,  
how can I remove the row of a dataframe whose selected column matches the value of another dataframe? essentially, is there an equivalent of R’s `%in%` operator in Julia?  
Thanks

---

<div class="post-metadata">

### Author: ![Tamas\_Papp](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tamas_papp/32/25949_2.png) [@Tamas\_Papp](https://discourse.julialang.org/u/Tamas_Papp)
#### Post date: [May 27, 2019, 11:06am UTC](https://discourse.julialang.org/t/delete-rows-that-exist-in-another-data-frame-in-julia/24645/2 "2019-05-27T11:06:43Z")

</div>

Please make an MWE for actual code.

> [@Please read: make it easier to help you](https://discourse.julialang.org/t/psa-make-it-easier-to-help-you/14757):
>
> Welcome to the Julia Discourse! We are enthusiastic about helping Julia programmers, both beginner and experienced. This public service announcement (PSA) outlines best practices when asking for help. Following these points makes it easier for us to help you and more likely you’ll get a prompt, useful answer. Keywords are highlighted to make it easier to refer to specific points. Choose a descriptive title that captures the key part of your question, eg “plots with multiple axes” instead of …

That said, you may find the following useful:

> [@Julia's in.() seems slow compared to R's %in%](https://discourse.julialang.org/t/julias-in-seems-slow-compared-to-rs-in/23900/):
>
> Hi everyone, I want to compare if elements of vector x are in elements of vector y. In R, I can do this as follows: \> x \<- c("a", "b", "c") \> y \<- c("b", "a") \> x %in% y [1] TRUE TRUE FALSE In Julia, I can do this as follows: julia\> x = ["a", "b", "c"]; julia\> y = ["b", "c"]; julia\> in.(x, Ref(y)) 3-element BitArray{1}: false true true Now let’s make the vector big: In R, \> set.seed(123) \> x \<- rnorm(100000, 1000, 2) \> y \<- rnorm(100000, 1000, 2) \> system.time(x %in% y) user sy…
