I have a list of over 400 species names. I also have two separate lists of names that are present in that original 400. What I want to do is make a presence/absence (1 and 0) data frame based on the two smaller lists. The two separate lists are as factors with levels equal to their length (unique species names), so each of those two are different lengths, and both smaller than the original 400.

Here is some of the names in two of those four separate lists:

```
    head(col.eff1)
    [1] Agapostemon sericeus  Agapostemon texanus   Agapostemon virescens Andrena rudbeckiae    Andrena simplex      
    [6] Anthophora terminalis
    head(inhs.eff1)
    [1] Agapostemon virescens Andrena carlini       Andrena personata     Andrena rudbeckiae    Augochlora pura      
    [6] Augochlorella aurata

```

I have tried the following to get the names

```
    intersect(col.eff1,inhs.eff1) ## what names do both lists have in common
    setdiff(col.eff1,inhs.eff1) ## what names does 1 have that 2 does not
    setdiff(inhs.eff1,col.eff1) ## what names does 2 have that 1 does not

```

These all work once I sort the lists before executing the code, but it only gives me the names.

But I need to make a single data frame, with 400 rows (rownames as species names), and two columns for the presence of species in collections and in sampling (inhs. and col.). \*\*I am doing this whole thing four different times too. 
Any help is appreciated, thank you!