-
Notifications
You must be signed in to change notification settings - Fork 8
Open
Description
Hello everyone,
I like to work with components which can be defined via the parent property (https://js.cytoscape.org/#notation/compound-nodes)
However, I do not define my network graph by hand my load a graphml-file via cytoscape.js-graphml:
var cy = window.cy = cytoscape({
container: document.getElementById('cy'),
ready: function () {
this.graphml({layoutBy: 'random'});
this.graphml(graphStr);
}
});
The graphml file looks like :
<?xml versi
on='1.0' encoding='utf-8'?>
<graphml xmlns="http://graphml.graphdrawing.org/xmlns" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://graphml.graphdrawing.org/xmlns http://graphml.graphdrawing.org/xmlns/1.0/graphml.xsd"><key attr.name="relationship" attr.type="string" for="edge" id="d8"/>
<key attr.name="node_name" attr.type="string" for="node" id="d0"/>
<key attr.name="parent" attr.type="long" for="node" id="d1"/>
<graph edgedefault="directed">
<node id="123">
<data key="d0">First</data>
<data key="d1">0</data>
</node>
<node id="124">
<data key="d0">Second</data>
<data key="d1">1</data>
</node>
...
Where d1 indicates the parent/component id. The question is, how do I define the parent variable of a node afterward. The graphml is automatically generated and can not be modified.
THX Lazloo
Metadata
Metadata
Assignees
Labels
No labels