Overview
- Project: Exploratory analysis of the
email-Eu-corenetwork from SNAP usingcode/cn-project.ipynb. - Goal: Load the email network, attach department labels, compute structural statistics (components, diameter, degree distribution, clustering, assortativity, centrality, core decomposition) and test community detection algorithms.
Notebook
- Main notebook: code/cn-project.ipynb
- Uses NetworkX and Matplotlib to reproduce the analyses and plots shown in the notebook.
Datasets
- Source: SNAP — https://snap.stanford.edu/data/email-Eu-core.html
- Files included:
- dataset/email-Eu-core.txt: edge list (one edge per line, space-separated:
source target). The file contains directed edges and a few self-loops. - dataset/email-Eu-core-department-labels.txt: mapping of node id to department id (one pair per line:
node department). There are 42 departments in the ground-truth labels.
- dataset/email-Eu-core.txt: edge list (one edge per line, space-separated:
Requirements
- Python 3.8+ recommended
- Main Python packages:
networkx,matplotlib,numpy,scipy
Quick setup
python -m venv .venv
.venv\Scripts\activate # Windows
pip install --upgrade pip
pip install networkx matplotlib numpy scipy jupyterRun
- Open the notebook in Jupyter or VS Code and run the cells in order. The notebook reads the datasets from
dataset/(relative path fromcode/where the notebook lives).
Notes & observations (from the notebook)
- The graph has ~1,005 nodes and ~25,571 edges (directed), and is sparse.
- Degree distribution is heterogeneous but shows an exponential cutoff (not a pure scale-free power law).
- Clustering coefficient and modularity comparisons with null models and algorithms are included.
- Department labels provide a ground-truth partition (42 departments) used to evaluate community detection methods (Girvan-Newman, Louvain, greedy modularity).
Credits
- Dataset: SNAP (Stanford Large Network Dataset Collection)