Skip to content

A research toolkit for multiplex networks: build layer tensors & supra-adjacency, analyze topology and mesoscale with SBM, compute multilayer centralities, and visualize layers in 3D.

License

Notifications You must be signed in to change notification settings

CoMuNeLab/MuxVizPy

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MuxVizPy

MuxVizPy is a Python package for multilayer and multiplex network analysis, inspired by the original MuxViz software.
It provides tools to compute centralities, structural descriptors, mesoscale properties, percolation, and versatile visualizations—backed by graph-tool and the scientific Python ecosystem.


Features

  • Construction of multilayer networks from CSV or metadata
  • Aggregate and supra-adjacency matrix utilities
  • Multiplex-aware centrality measures:
    • Eigenvector, Katz, Random Walk (PageRank/classical), Hub, Authority, K-Core
  • Topological descriptors:
    • Largest connected components, shortest-path matrices, similarity
  • Mesoscale analysis:
    • Modularity, blockmodels, assortativity
  • Percolation analysis
  • 3D multilayer network visualization with matplotlib

Installation

# Clone the repository
git clone https://github.com/your-username/MuxVizPy.git
cd MuxVizPy

# (Recommended) Create a virtual environment
python -m venv venv
source venv/bin/activate  

# Install dependencies
pip install -e .

⚠️ Note: graph-tool is not pip-installable.
Install it manually via official instructions or using conda:

conda install -c conda-forge graph-tool

Basic Usage

For a basic usage script see the file scripts/test.py


Project Structure

├── pyproject.toml
├── README.md
├── LICENSE
├── scripts
│   ├── example_data
│   │   ├── metadata.csv
│   │   ├── VirusA
│   │   │   ├── edges.csv
│   │   │   └── nodes.csv
│   │   ├── VirusB
│   │   │   ├── edges.csv
│   │   │   └── nodes.csv
│   │   └── VirusC
│   │       ├── edges.csv
│   │       └── nodes.csv
│   └── test.py
└── src
    ├── MuxVizPy
       ├── build.py
       ├── core.py
       ├── __init__.py
       ├── leading_eigenv_approx.py
       ├── mesoscale.py
       ├── percolation.py
       ├── plotMux.py
       ├── topology.py
       ├── utils.py
       ├── versatility.py
       └── visualization.py

Requirements

  • Python ≥ 3.8
  • numpy, scipy, pandas, matplotlib, tqdm
  • graph-tool (system package)

License

MIT License 2025

Acknowledgements

  • Inspired by the original MuxViz platform.
  • Built with graph-tool, a performant graph analysis library.

About

A research toolkit for multiplex networks: build layer tensors & supra-adjacency, analyze topology and mesoscale with SBM, compute multilayer centralities, and visualize layers in 3D.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •  

Languages