You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If given a query graph with duplicate nodes by id (for example, two instances of HP:0100775, but with a source_disease attribute added with values "eds" and "marfan"), then expand() will only expand edges from one of them; it should do all.
The reason is because expand() (for both file engines and neo4j engines) uses tidygraph's graph_join() to join the query graph with the fetched result graph, and graph_join() does not add such edges (nor will it even when joining graphs with exactly duplicate nodes).
To fix this I propose adding a kg_join() function as a more-expansive version of tidygraph's graph_join() which replicates any edges (according to id) across all node pairs in the node and edge data, and using that in expand(). This would be a useful function anyway when working with more advanced use cases.
The text was updated successfully, but these errors were encountered:
If given a query graph with duplicate nodes by
id
(for example, two instances ofHP:0100775
, but with asource_disease
attribute added with values"eds"
and"marfan"
), thenexpand()
will only expand edges from one of them; it should do all.The reason is because
expand()
(for both file engines and neo4j engines) uses tidygraph'sgraph_join()
to join the query graph with the fetched result graph, andgraph_join()
does not add such edges (nor will it even when joining graphs with exactly duplicate nodes).To fix this I propose adding a
kg_join()
function as a more-expansive version of tidygraph'sgraph_join()
which replicates any edges (according toid
) across all node pairs in the node and edge data, and using that inexpand()
. This would be a useful function anyway when working with more advanced use cases.The text was updated successfully, but these errors were encountered: