View source: R/utils-set-operations.R
nb_union | R Documentation |
Perform set operations element-wise on two lists of equal length.
nb_union(x, y)
nb_intersect(x, y)
nb_setdiff(x, y)
x |
list of class |
y |
list of class |
nb_union()
returns the union of elements in each element of x and y
nb_intersect()
returns the intersection of elements in each element of x and y
nb_setdiff()
returns the difference of elements in each element of x and y
A list of class nb
nb <- st_contiguity(guerry$geometry)
nb_knn <- st_knn(guerry$geometry, k = 3)
nb_setdiff(nb, nb_knn)
nb_union(nb, nb_knn)
nb_intersect(nb, nb_knn)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.