NetworkX
2.1
Install
Tutorial
Reference
Introduction
Graph types
Algorithms
Approximations and Heuristics
Assortativity
Bipartite
Boundary
Bridges
Centrality
Chains
Chordal
Clique
Clustering
Coloring
Communicability
Communities
Components
Connectivity
Cores
Covering
Cycles
Cuts
Directed Acyclic Graphs
Dispersion
Distance Measures
Distance-Regular Graphs
Dominance
Dominating Sets
Efficiency
Eulerian
Flows
Graphical degree sequence
Hierarchy
Hybrid
Isolates
Isomorphism
Link Analysis
Link Prediction
Matching
Minors
Maximal independent set
Operators
Reciprocity
Rich Club
Shortest Paths
networkx.algorithms.shortest_paths.generic.shortest_path
networkx.algorithms.shortest_paths.generic.all_shortest_paths
networkx.algorithms.shortest_paths.generic.shortest_path_length
networkx.algorithms.shortest_paths.generic.average_shortest_path_length
networkx.algorithms.shortest_paths.generic.has_path
Advanced Interface
Dense Graphs
A* Algorithm
Simple Paths
Structural holes
Swap
Tournament
Traversal
Tree
Triads
Vitality
Voronoi cells
Wiener index
Functions
Graph generators
Linear algebra
Converting to and from other data formats
Relabeling nodes
Reading and writing graphs
Drawing
Exceptions
Utilities
Glossary
Developer Guide
Release Log
License
Credits
Citing
Bibliography
Examples
NetworkX
Docs
»
Reference
»
Algorithms
»
Shortest Paths
»
networkx.algorithms.shortest_paths.generic.has_path
networkx.algorithms.shortest_paths.generic.has_path
¶
has_path
(
G
,
source
,
target
)
[source]
¶
Return
True
if
G
has a path from
source
to
target
.
Parameters:
G
(
NetworkX graph
)
source
(
node
) – Starting node for path
target
(
node
) – Ending node for path