I have two undirected graphs
library(igraph)
g1 <- make_graph( edges=c("A", "B", "B", "C", "C", "A"), directed=F )
g2 <- make_graph( edges=c("A", "B", "B", "C", "A", "C", "C", "D"), directed=F )
I want to compare the edges of g1 to g2 graphs. I want to count the number of edges that are exactly the same, as well as the number of edges that are reversed (e.g. A->C changes to C->A as in undirected network both imply as similar edge), and the number of additional edges.
Is there a simple function for doing this sort of comparison of edges? Could anyone please help me to solve this.