graphreadability
Python module for applying readability metrics to network and graph visualizations. This project is a work in progress that is being developed by Philip Mathieu (MS DS Student) as part of the Research Apprenticeship program at Northeastern University's Khoury College of Computer Science.
Usage
import networkx as nx
import graphreadability as gr
# Create a basic graph using NetworkX
G = nx.Graph()
G.add_nodes_from(
[
(1, {"x": 1, "y": 1}),
(2, {"x": -1, "y": 1}),
(3, {"x": -1, "y": -1}),
(4, {"x": 1, "y": -1}),
(5, {"x": 2, "y": 1}),
]
)
G.add_edges_from([(1, 2), (2, 3), (3, 4), (4, 2), (1, 3)])
# Create a MetricsSuite to calculate readability metrics
M = gr.MetricsSuite(G)
M.calculate_metrics()
M.pretty_print_metrics()
Utilities
Graph Digitizer
This utility is a python package using matplotlib to show and image and allowing the user to click to add nodes, right click to delete nodes, and click two nodes sequentially to add edges.
python graphreadability/utils/digitize_graphs.py -h
usage: digitize_graphs.py [-h] [-i IMAGE] [-o OUTPUT]
Create a graph from an image.
options:
-h, --help show this help message and exit
-i IMAGE, --image IMAGE
Path to the image to create a graph from.
-o OUTPUT, --output OUTPUT
Path to save the graph to.
Sources Cited
Metric definitions are derived from:
- C. Dunne, S. I. Ross, B. Shneiderman, and M. Martino. "Readability metric feedback for aiding node-link visualization designers," IBM Journal of Research and Development, 59(2/3) pages 14:1--14:16, 2015.
Initial inspiration was taken from rpgove/greadability.js.
Code in graphreadability/metrics/ is in part derived from code originally published at https://github.com/gavjmooney/graph_metrics/ associated with the following publication:
@Conference{citekey,
author = "Gavin J. Mooney, Helen C. Purchase, Michael Wybrow, Stephen G. Kobourov",
title = "The Multi-Dimensional Landscape of Graph Drawing Metrics",
booktitle = "2024 IEEE 17th Pacific Visualization Symposium (PacificVis)",
year = "2024",
}
License
Apache 2.0 - see LICENSE.txt
Metadata
Release files for graphreadability 0.0.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| graphreadability-0.0.3.tar.gz | 33.6 kB | Without provenance | Details for graphreadability-0.0.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| graphreadability-0.0.3-py3-none-any.whl | Python 3 | none | any | Details for graphreadability-0.0.3-py3-none-any.whl |
Total release size: 74.2 kB
Release files / graphreadability-0.0.3.tar.gz
| Download URL | graphreadability-0.0.3.tar.gz |
|---|---|
| Size | 33.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
fd68c253a07dba65b840be28e719c8adefe5a5605fffb204f17c322dd19bd0bb
|
|
BLAKE2b-256 checksum How to use checksums |
a66c8f6aacb3dd2e6ad375e30dee4c6b58acc73ed7cf03621d5bddd705db0f56
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/5.0.0 CPython/3.12.2
|
Release files / graphreadability-0.0.3-py3-none-any.whl
| Download URL | graphreadability-0.0.3-py3-none-any.whl |
|---|---|
| Size | 40.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
26400756198894be3360a5ebbfd330d3eb0a68dc8b180e56353de881989ba1c4
|
|
BLAKE2b-256 checksum How to use checksums |
a70630254f4169df8986e1d3100f04aa9520a0774f70d0a4dacfb253a90a9af2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/5.0.0 CPython/3.12.2
|
Security for graphreadability 0.0.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.