adjacency matrices and direct network...

Get help with your data
Post Reply [phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1275: count(): Parameter must be an array or an object that implements Countable
cecitomassini
Posts:9
Joined:29 Oct 2016 16:35
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1275: count(): Parameter must be an array or an object that implements Countable
adjacency matrices and direct network...

Post by cecitomassini » 26 Nov 2016 23:04

Hello!

First I want to say thank you for all the work you have done! The program is really great!. It really helps me a lot with my PhD thesis.

So, I have worked with non-directed networks.
But now I have a direct network and I have some problems determining the source and target.

I have adjacency matrices of about 500 nodes. With universities and financing institutions. Connections range from funding institutions to universities.

Financing1 Financing2
University 1 0 1
University 2 1 1

There are many cases, so I cannot make a two-column list with source and target.

Is there any way I can do it in the adjacency matrices? or after I open the file in Gephi?

Thank you very much for your help!
Cecilia

User avatar
eduramiba
Gephi Code Manager
Posts:1064
Joined:22 Mar 2010 15:30
Location:Madrid, Spain
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1275: count(): Parameter must be an array or an object that implements Countable

Re: adjacency matrices and direct network...

Post by eduramiba » 26 Nov 2016 23:18

Hi,

CSV format (https://gephi.org/users/supported-graph ... sv-format/) supports adjacency matrix. Note it's different than spreadsheet format (use File - Open...).

cecitomassini
Posts:9
Joined:29 Oct 2016 16:35
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1275: count(): Parameter must be an array or an object that implements Countable

Re: adjacency matrices and direct network...

Post by cecitomassini » 27 Nov 2016 03:32

Hello, thanks for the answer.

I did not mean that, I actually use the .csv format without any problems.

The question is, how does Gephi know the direction of the "arrows" in a matrix?

I know that in a list it is: (source "A"> Target "B" or A;B)

But how do I determine the source and target in an adjacency matrix?
Like this:

in this case the target are the B and the source the A, how Gephi can knows that?

; A1;A2;A3;A4;A5
B1;0 ;1 ;0 ;1 ;0
B2;1 ;0 ;0 ;6 ;0
B3;0 ;6 ;1 ;0 ;0
B4;0 ;1 ;0 ;1 ;12
B5;0 ;0 ;0 ;0 ;0

Sorry for my english!

Thanks!
Cecilia

User avatar
eduramiba
Gephi Code Manager
Posts:1064
Joined:22 Mar 2010 15:30
Location:Madrid, Spain
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1275: count(): Parameter must be an array or an object that implements Countable

Re: adjacency matrices and direct network...

Post by eduramiba » 27 Nov 2016 14:34

Hi,
Note that is not a correct adjacency matrix. All nodes should be present in the first row and the first column.

Then, edges start from the left column node, and target the first row node.

For example:

Code: Select all

;A1;A2;A3;A4;A5
A1;0;0;0;0;1
A2;0;0;0;0;0
A3;0;0;0;0;0
A4;0;0;0;0;1
A5;1;0;0;0;0
This creates an edge from A1 to A5, an edge from A4 to A5 and an edge from A5 to A1.

User avatar
eduramiba
Gephi Code Manager
Posts:1064
Joined:22 Mar 2010 15:30
Location:Madrid, Spain
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1275: count(): Parameter must be an array or an object that implements Countable

Re: adjacency matrices and direct network...

Post by eduramiba » 27 Nov 2016 14:37

Alternatively, you could use the adjacency list format shown at https://gephi.org/users/supported-graph ... csv-format and format your file as:

Code: Select all

University 1;Financing2
University 2;Financing1;Financing2

cecitomassini
Posts:9
Joined:29 Oct 2016 16:35
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1275: count(): Parameter must be an array or an object that implements Countable

Re: adjacency matrices and direct network...

Post by cecitomassini » 27 Nov 2016 15:21

Thank you, Gracias, Obrigada!!

You gave me the key: I had to correctly place the sources in the rows and the target in the columns.
I could do it.

Really, thank you very much!

Post Reply
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1275: count(): Parameter must be an array or an object that implements Countable
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1275: count(): Parameter must be an array or an object that implements Countable