How can I remove all the nodes in my graph without edges
6 ビュー (過去 30 日間)
古いコメントを表示
Hi,
I have a adjancey matrix with some nodes that dont have any edges, just NaN values for the edge values. How can I remove all the nodes that do not have edges?
Many thanks in advance,
Nima
0 件のコメント
回答 (1 件)
Steven Lord
2019 年 7 月 24 日
If you've created a graph or digraph object from your adjacency matrix take a look at the degree, indegree, outdegree, and/or rmnode functions.
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Graph and Network Algorithms についてさらに検索
製品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!