# Remove lines from a list that doesn't appear in another list

**URL:** <https://discourse.mcneel.com/t/remove-lines-from-a-list-that-doesnt-appear-in-another-list/62634>\
**Category:** GH for Mac\
**Created:** [May 12, 2018, 5:32pm UTC](https://discourse.mcneel.com/t/remove-lines-from-a-list-that-doesnt-appear-in-another-list/62634 "2018-05-12T17:32:41Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![StructureEmma](https://sea3.discourse-cdn.com/mcneel/user_avatar/discourse.mcneel.com/structureemma/32/86433_2.png) [@StructureEmma](https://discourse.mcneel.com/u/StructureEmma)\
**Post date:** [May 12, 2018, 5:32pm UTC](https://discourse.mcneel.com/t/remove-lines-from-a-list-that-doesnt-appear-in-another-list/62634/1 "2018-05-12T17:32:42Z")

</div>

Hello,  
I am trying to use ‘cull pattern’, but I can’t find out what I am doing wrong… I have 2 lists of lines, and I want to keep all the lines in list 1 that are also in list 2. So every element of list 1 that isn’t in 2 need to be removed. So I used ‘equal’ but I only have 1 line over, instead of nearly all the lines… Is there another command I need to use for this? Thanks!

 ![58](https://global.discourse-cdn.com/mcneel/original/3X/2/a/2aa45d1ba0aa543019cfdfab7bda6c40f60ab81f.png)

---

<div class="post-metadata">

**Author:** ![tim.stark](https://sea3.discourse-cdn.com/mcneel/user_avatar/discourse.mcneel.com/tim.stark/32/704108_2.png) [@tim.stark](https://discourse.mcneel.com/u/tim.stark)\
**Post date:** [May 12, 2018, 6:52pm UTC](https://discourse.mcneel.com/t/remove-lines-from-a-list-that-doesnt-appear-in-another-list/62634/2 "2018-05-12T18:52:52Z")

</div>

Without your definition, it’s hard to tell you what went wrong…

Have a look at this: Same problem, keeping lines which appear in both lists.

> [@Developing the 3d isovist to optimization](https://discourse.mcneel.com/t/developing-the-3d-isovist-to-optimization/62582):
>
> Im trying to make a version of isovist that can give me the optimize place for my building to be maximum seen from a path. I need a componant that could give me a list with the items that are included in two other lists. I am not sure if this is the only proplem, if you have any other idea slight_smile[2D 3D isovist-1.gh](https://global.discourse-cdn.com/mcneel/uploads/default/original/3X/5/d/5d2fbb0d1896c605b31cde1f44d6fb74b42d8e92.gh) (38.0 KB) [isovist-1.3dm](https://global.discourse-cdn.com/mcneel/uploads/default/original/3X/9/e/9e47d5f2ea545ea664582c03c913c93b53dfeb1b.3dm) (66.1 KB)

---

<div class="post-metadata">

**Author:** ![StructureEmma](https://sea3.discourse-cdn.com/mcneel/user_avatar/discourse.mcneel.com/structureemma/32/86433_2.png) [@StructureEmma](https://discourse.mcneel.com/u/StructureEmma)\
**Post date:** [May 12, 2018, 7:16pm UTC](https://discourse.mcneel.com/t/remove-lines-from-a-list-that-doesnt-appear-in-another-list/62634/3 "2018-05-12T19:16:25Z")

</div>

Hi, thanks for the answer. My gh file is complicated for the moment and not so organized, so showing it would make everything more unclear I think 😛 My problem actually started when I split lines with a plane, and gh doesn’t split them ‘precisely enough’, so wen splitting I get much more points and small lines of 0,0 en 0,0001 mm then needed… And I wanted to eliminate them again by saying only the lines from my beginning list should still be there. I did now with ‘larger than’ to eliminate those small lines which worked, but I wanted to know if my end lines were still exactly the same as my input, without change of some mm in the length. But I think my explanation makes it more complicated. I will look to put just that part separated in a file to make more clear … 😃 I am missing some plugins to look at your gh file completely.
