[phpBB Debug] PHP Warning: in file [ROOT]/phpbb/session.php on line 583: sizeof(): Parameter must be an array or an object that implements Countable
[phpBB Debug] PHP Warning: in file [ROOT]/phpbb/session.php on line 639: sizeof(): Parameter must be an array or an object that implements Countable
Gephi forumsPlease post new questions on facebook group too (https://www.facebook.com/groups/gephi) 2018-03-11T18:32:10+01:00 https://forum-gephi.org/app.php/feed/topic/6473 2018-03-11T18:32:10+01:002018-03-11T18:32:10+01:00 https://forum-gephi.org/viewtopic.php?t=6473&p=15063#p15063 <![CDATA[Re: Parallel Edges and Self Loops]]>
Just like when importing in gephi a file, during import report you choose wether to merge parallel edges or not (merge strategy).
You should configure that in the container in your code too.

Statistics:Posted by eduramiba — 11 Mar 2018 18:32


]]>
2018-03-10T22:26:17+01:002018-03-10T22:26:17+01:00 https://forum-gephi.org/viewtopic.php?t=6473&p=15061#p15061 <![CDATA[Parallel Edges and Self Loops]]> There are selfLoops and ParallelEdges in the graph. So I tried to set those functions to true last 2 lines in the following:

projectControllerA = Lookup.getDefault().lookup(ProjectController.class);
projectControllerA.newProject();
workspaceA = projectControllerA.getCurrentWorkspace();
importcontrollerA = Lookup.getDefault().lookup(ImportController.class);
graphModelA = Lookup.getDefault().lookup(GraphController.class).getGraphModel(workspaceA);
graphModelA.getNodeTable().addColumn("isPresented", boolean.class);
graphModelA.getEdgeTable().addColumn("isExpanded", boolean.class);
File inFileA = new File(inFileName);
container = importcontrollerA.importFile(inFileA);
container.getLoader().setAllowParallelEdge(true);
container.getLoader().setAllowSelfLoop(true);

The input file follows note there are 9 edges. The output file only has 7 edges no self loops or parallel edges.
Are these methods implemented?
If so, can someone show me what I need to do differently?
I put an attribute of kind="0.." after the target in the edge specification, and I then got all my edges.
It would seem to me that the id distinguishes the edge and to further uniquely identify should not be unnecessary.

<gexf xmlns="http://www.gexf.net/1.2draft" version="1.2">
<meta lastmodifieddate="20180312">
<creator>Bob Garvey</creator>
<description>The graph in the patent. Trying for parallel edges.</description>
</meta>
<graph mode="static" defaultedgetype="directed">
<nodes>
<node id="1" label="N2" />
<node id="0" label="N1" />
<node id="2" label="N3" />
<node id="3" label="N4" />
<node id="4" label="N5" />
<node id="5" label="N6" />
<node id="6" label="N7" />
</nodes>
<edges>
<edge id="0" source="0" target="1" />
<edge id="1" source="0" target="1" />
<edge id="2" source="0" target="2" />
<edge id="3" source="2" target="0" />
<edge id="4" source="1" target="3" />
<edge id="5" source="2" target="3" />
<edge id="6" source="3" target="3" />
<edge id="7" source="4" target="5" />
<edge id="8" source="3" target="3" />
</edges>
</graph>
</gexf>
Changes that then worked:
<edge id="0" source="0" target="1" kind="0"/>
<edge id="1" source="0" target="1" kind="1"/>........

Statistics:Posted by bgarvey — 10 Mar 2018 22:26


]]>