[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
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4516: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3262)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4516: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3262)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4516: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3262)
Gephi forums •[SOLVED] how to convert a txt file to gexf file?
Page 1 of 1

[SOLVED] how to convert a txt file to gexf file?

Posted: 09 Jun 2011 04:45
by cookies713
Since my dataset is in txt file and the specific manifestation like this:
42051169 51923155 0
42051169 51923155 0.3
42051169 64029985 0.5
.........
so what can i do to meet the Gephi's requirement.Thank you!

Re: how to convert a txt file to gexf file?

Posted: 09 Jun 2011 09:28
by admin
What is the meaning of the columns?

Re: how to convert a txt file to gexf file?

Posted: 09 Jun 2011 10:31
by cookies713
admin wrote:What is the meaning of the columns?
It is about a social network dataset.To be specific,the first two columns give two participants' ID number,and last column lists the two users' relationship,which can be regarded as the uncertain edge existing probability of the graph.

Re: how to convert a txt file to gexf file?

Posted: 09 Jun 2011 10:51
by admin
Ok so you should create a DL file to put the edge list.

The last column is can be seen as the "weight" of the edges. I advise to multiply the probabilities by 100 so that the layouts can use them properly.

So you'll have a file like this, given the 3 nodes of your example:

Code: Select all

dl
format=edgelist1
n=3
data:
42051169 51923155 0
42051169 51923155 30
42051169 64029985 50

Re: how to convert a txt file to gexf file?

Posted: 10 Jun 2011 08:04
by seinecle
Hi,

To complement what Sebastien said: once you have your dl file: open it in Gephi, then you can save it as a gexf file.

Best,

Clement