-
Notifications
You must be signed in to change notification settings - Fork 4
Open
Labels
Description
It would be great if for walker functions instead of allowing a single predicate, multiple predicates would be allowed. A recent use-case for me was to find all children of a given GO term related through part_of or is_a relationships. To do that I had to filter out relationships in the json before parsing the graph, but it would be nice to be able to do this within the library, providing a list instead of a string for the in_pred aragument in functions like the one below:
Lines 1091 to 1099 in 8837355
| graph.prototype.get_parent_edges = function(nb_id, in_pred){ | |
| var anchor = this; | |
| var results = []; | |
| // Get all parents, or just parents from a specific relation. | |
| var preds_to_use = []; | |
| if( in_pred ){ | |
| preds_to_use.push(in_pred); |
Reactions are currently unavailable