subgraph_isomorphisms for considering absent edge

Hi everyone!

I’m running subgraph_isomorphisms with V2 method and get a question here:
if I query pattern:
g1 = make_graph(edges =c(1,2,2,3,1,3), directed = FALSE)
with color1 = c(1,2,3)
g2 = make_graph(edges =c(1,2,2,3), directed = FALSE)
with color2 = c(1,2,3)

in the same big graph, the result produced by g1 is actually a subset of the result of g2.
Could I ask in this case, if I do not want patterns that connect 1 and 3, how do I query with the function?
Thanks so much and please let me know if I could provide other informations!

Use the 'lad' method and set induced=TRUE

Thank you. Could I ask what if my nodes have colors? Does lad also support node color? I did not see color arguments for lad.

Yes, you can achieve the same by using an appropriate domains argument. For each vertex, give the list of other vertices with the same colour. See the documentation for details. I’m sorry, I don’t have time to write an example now.