Closed Chengwei94 closed 2 years ago
Hi @Chengwei94,
If you check the connectivities matrix you will see that only the nearest neighbours of any node have a non-zero connectivity (the same nodes that also have a reported distance). Thus, the whole graph will not necessarily be connected when using connectivities. Connetivities are a function of distance (I would have to look up exactly what that function is) that is scaled between 0 and 1 and is inversely related to distance. Thus, it is more fitting than distances here.
Hi there,
shouldnt graph connectivity use adata.obsp["distances"] or some sort of shared nearest neighbors as the graph, since that adata.obsp["connectivities"] might connect distant nodes together to ensure that the whole graph is connected and lead to spurious edges?