Skip to main content

BiRankpy

Bipartite (two-mode) networks are ubiquitous. When calculating node centrality measures in bipartite networks, a common approach is to apply PageRank on the one-mode projection of the network. However, the projection can cause information loss and distort the network topology. For better node ranking on bipartite networks, it is preferable to use a ranking algorithm that fully accounts for the topology of both modes of the network.

We present the BiRank package, which implements bipartite ranking algorithms HITS, CoHITS, BGRM, and Birank. BiRank provides convenience options for incorporating node-level weights into rank estimations, allowing maximum flexibility for different purpose. It can efficiently handle networks with millions of nodes on a single midrange server. Both R and Python versions.

Overview

birankpy provides functions for estimating various rank measures of nodes in bipartite networks including HITS, CoHITS, BGRM, and Birank. It can also project two-mode networks to one-mode, and estimat PageRank on it. birankpy allows user-defined edge weights. Implemented with sparse matrix, it's highly efficient.

Example

Let's pretend we have a edge list edgelist_df containing ties between top nodes and bottom nodes:

top_node bottom_node
1 a
1 b
2 a

To performing BiRank on, just:

bn = birankpy.BipartiteNetwork()

bn.set_edgelist(edgelist_df,  top_col='top_node', bottom_col='bottom_node')

top_birank_df, bottom_birank_df = bn.generate_birank()

Release files for birankpy 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for birankpy 0.1.1
File Size Uploaded
birankpy-0.1.1.tar.gz 6.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for birankpy 0.1.1
File Interpreter ABI Platform
birankpy-0.1.1-py3-none-any.whl Python 3 none any Details

Total release size: 12.4 kB

Release files / birankpy-0.1.1.tar.gz

Download URL birankpy-0.1.1.tar.gz
Size 6.3 kB
Tags Source
SHA-256 checksum
How to use checksums
222d3590d50ec23b6cffc4d245b7d1d92ce6e4ae753bb622d88fb9476e5a0506
BLAKE2b-256 checksum
How to use checksums
230a34a24c444d465a28c22a431ff755b5137df88772e023759004a6d1a52c14
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/45.1.0 requests-toolbelt/0.9.1 tqdm/4.42.1 CPython/3.7.4

Release files / birankpy-0.1.1-py3-none-any.whl

Download URL birankpy-0.1.1-py3-none-any.whl
Size 6.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
c4004b94f165f3e5cb27527197df46617cbb3e17eda1765e4c219da22b25cc7b
BLAKE2b-256 checksum
How to use checksums
c4392e45afcd982f853eefa5eddf8828f2408081d370027d4d93b88a58bdea43
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/45.1.0 requests-toolbelt/0.9.1 tqdm/4.42.1 CPython/3.7.4

Release history Release notifications | RSS feed

1.0.1

2 release files

1.0.0

2 release files

This release

0.1.1 This release

2 release files

0.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page