scipy.cluster.hierarchy.DisjointSet.

connected#

DisjointSet.connected(x, y)[source]#

Test whether x and y are in the same subset.

Parameters:
x, yhashable object

Elements to test.

Returns:
resultbool

True if x and y are in the same set, False otherwise.