*****  To join INSNA, visit  *****

Dear All,

In the past several years, I have been using generalized similarity measure
for bipartite graphs, whereas two nodes in one partition are similar if
they are adjacent to similar nodes in the other partition, and vice versa.
The algorithm for calculateing generalized similarities was described
by Balázs Kovács in "A generalized model of relational similarity," Social
Networks, 32(3), July 2010, pp. 197–211.

I wrote a Python module that uses NetworkX and NumPy to calculate
generalized similarities in a connected undirected bipartite graph (e.g.,
representing words and documents). The module provides
function generalized_similarity() that takes a NetworkX graph (naturally,
bipartite) and returns two similarity graphs for the nodes in either
partition. The module also provides function test_generalized_similarity()
that applies the algorithm to the "classical" Southern Women graph.

The module is known to work for connected undirected graphs. I have not
tested it for directed or unconnected graphs yet.

The module is available for download and non-commercial use at Any feedback would be
highly appreciated.

See you at Newport Beach in April!

Dmitry Zinoviev
Professor of Computer Science
Suffolk University, Boston, MA 02114

SOCNET is a service of INSNA, the professional association for social
network researchers ( To unsubscribe, send
an email message to [log in to unmask] containing the line
UNSUBSCRIBE SOCNET in the body of the message.