Closed Anaphory closed 2 years ago
Currently, the lapply in https://github.com/luukvdmeer/sfnetworks/blob/906f423c2594313a67b89aeaecc4ed561a86c396/R/morphers.R#L667 calls a function which in every call – i.e. for every subgraph (at least not for every edge, as I originally thought) – tests whether the graph is directed or not: https://github.com/luukvdmeer/sfnetworks/blob/906f423c2594313a67b89aeaecc4ed561a86c396/R/morphers.R#L583-L589 Would it not make sense to define find_edges differently for directed and undirected graphs, ie. essentially swapping lines 583 and 589 (with a copy of line 583 in the else, between 625 and 626)?
lapply
find_edges
Fixed in v0.6.0
Currently, the
lapply
in https://github.com/luukvdmeer/sfnetworks/blob/906f423c2594313a67b89aeaecc4ed561a86c396/R/morphers.R#L667 calls a function which in every call – i.e. for every subgraph (at least not for every edge, as I originally thought) – tests whether the graph is directed or not: https://github.com/luukvdmeer/sfnetworks/blob/906f423c2594313a67b89aeaecc4ed561a86c396/R/morphers.R#L583-L589 Would it not make sense to definefind_edges
differently for directed and undirected graphs, ie. essentially swapping lines 583 and 589 (with a copy of line 583 in the else, between 625 and 626)?