networkx

Create, analyze, and visualize complex networks and graphs in Python.

Updated Jun 6, 2026
One-click install
npx skills add https://github.com/Ritabrata-Chakraborty/Claude-Setup --skill networkx-ritabrata-chakraborty
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: networkx
Source: https://github.com/Ritabrata-Chakraborty/Claude-Setup/tree/main/skills/networkx
Command: npx skills add https://github.com/Ritabrata-Chakraborty/Claude-Setup --skill networkx-ritabrata-chakraborty

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires networkx, and includes scripts (resource) and references (resource) and assets (resource) components.

What problem does it solve?

This Skill provides a comprehensive toolkit for creating, analyzing, and visualizing complex networks and graphs in Python, enabling users to work with network data structures, compute graph algorithms, and generate synthetic networks.

Core Features & Use Cases

  • Graph Creation and Manipulation: Build and modify various graph types (Graph, DiGraph, MultiGraph, MultiDiGraph).
  • Graph Analysis: Compute centrality measures, shortest paths, detect communities, and analyze connectivity.
  • Graph Algorithms: Run algorithms like Dijkstra's, PageRank, minimum spanning trees, and maximum flow.
  • Network Generation: Create synthetic networks for testing or simulation.
  • Graph I/O: Read and write graphs in various formats (edge lists, GraphML, JSON, CSV, adjacency matrices).
  • Visualization: Draw and customize network visualizations with matplotlib or interactive libraries.
  • Use Case: If you are working on a social network analysis project and need to visualize the relationships between individuals, this Skill can help you create and analyze the graph data.

Quick Start

Use the networkx skill to create a graph from an edge list and compute the shortest path between two nodes.

Frequently Asked Questions about networkx

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I compute shortest paths and centrality measures for network data in Python?

To compute shortest paths and centrality measures for network data, you can create a graph from an edge list and apply built-in graph algorithms to analyze pairwise relationships and connectivity.

What is the best way to visualize complex networks and graph relationships?

The best way to visualize complex networks is by constructing graph data structures and applying visualization techniques with matplotlib to render and customize the network relationships.

Can I use networkx for social network analysis and community detection?

Yes, you can use networkx for social network analysis by building graphs from relationship data, detecting communities, and computing centrality to identify key individuals within the network.

How do I read and write graph data formats like GraphML, JSON, and CSV edge lists?

You can read and write graph data formats like GraphML, JSON, and CSV edge lists by using graph I/O functions to import and export network data structures from adjacency matrices or edge lists.

Does networkx support directed graphs and algorithms like PageRank and maximum flow?

Yes, networkx supports directed graph types like DiGraph and runs algorithms including PageRank, Dijkstra's, minimum spanning trees, and maximum flow for complex network analysis.

How do I generate synthetic networks for testing graph algorithms?

You can generate synthetic networks for testing graph algorithms by using built-in network generation functions to create synthetic graph data structures for simulation and analysis.