igraph-help
[Top][All Lists]

## Re: [igraph] how to compare two networks...

 From: Gabor Csardi Subject: Re: [igraph] how to compare two networks... Date: Mon, 21 Apr 2008 10:48:34 +0200 User-agent: Mutt/1.5.13 (2006-08-11)

```Personally i don't know much about QAP, sna seems to have a
function for it (qaptest).

FYI,
G.

On Sun, Apr 20, 2008 at 11:54:22PM +0200, Simone Gabbriellini wrote:
> Tamas,
>
> yes you are right!!!! and in my case multiple links do matter!!! I
> knew it was better to stick to igraph! ;)
>
> last question: I have one empirical network and 100 simulated
> networks... any hints on how to evaluate the significance of all
> Hamming distances to the empirical net? Something like QAP test...
>
> many thanks,
>
> Simone
>
>
> Il giorno 19/apr/08, alle ore 00:53, Tamas Nepusz ha scritto:
>
> >Dear Simone,
> >
> >I think the difference lies between how igraph and sna handles
> >multiple edges. Both of your networks have multiple edges. sna
> >collapses multiple edges into one single edge and then takes the
> >symmetric difference of the two edge sets -- at least that is what I
> >assume, since I obtained the same result in Python after doing these
> >operations manually on your networks (hdist = 611). Strictly
> >speaking, this method is incorrect if there are multiple edges and
> >they have to be taken into account. In this sense, the approach
> >described by Gabor is better: get the adjacency matrices, take the
> >difference of the two matrices, take the absolute value of every
> >element in the difference matrix and then sum the elements. This
> >results in a Hamming distance of 664. sna simply does not count the
> >cases where there are two edges from A to B in one of the networks
> >and only one in the other.
> >
> >--
> >T.
> >
> >On 2008.04.19., at 0:36, Simone Gabbriellini wrote:
> >
> >>Gabor,
> >>
> >>I see the small graphs solution is good for me, it works easy but,
> >>compared to hdist in sna package, I have a different results. And
> >>even your two solutions bring to different outcomes on the same two
> >>networks... it's all about ten/twenty edges more or less:
> >>
> >>small graphs: 657
> >>hdist (sna): 611
> >>large graphs: 664
> >>
> >>I have attached the file for testing, if you have the time.
> >>
> >>regards,
> >>Simone
> >>
> >><simulated-1.net><empirico.net>
> >>
> >>>
> >>>
> >>>igraph-help mailing list
> >>>http://lists.nongnu.org/mailman/listinfo/igraph-help
> >>
> >>_______________________________________________
> >>igraph-help mailing list
> >>http://lists.nongnu.org/mailman/listinfo/igraph-help
> >
> >
> >
> >_______________________________________________
> >igraph-help mailing list
> >http://lists.nongnu.org/mailman/listinfo/igraph-help
>
>
>
> _______________________________________________
> igraph-help mailing list