pcp1 <- create_component("MULTIPOINT((2 2), (2 4), (2 0))", 0.5)
pcp2 <- create_component("MULTIPOINT((1 1), (3 1), (1 3), (3 3))", 0.9)
pcp3 <- create_component("POINT(2 2)", 0.2)
pcp4 <- create_component("MULTIPOINT((1 1), (3 3))", 0.7)
ppoint1 <- create_pgeometry(list(pcp1, pcp2), "PLATEAUPOINT")
ppoint2 <- create_pgeometry(list(pcp3, pcp4), "PLATEAUPOINT")
# is ppoint2 completely and certainly inside ppoint1?
spa_exact_inside(ppoint2, ppoint1)
# The order of operands after the result
# ppoint1 is not inside ppoint2 since it has different points
spa_exact_inside(ppoint1, ppoint2)
Run the code above in your browser using DataLab