Colouring of my Graph
4 ビュー (過去 30 日間)
古いコメントを表示
So I have a graph of my imported messurements, and i would like to colour different parts of it with different colours. Any ideas??
2 件のコメント
Walter Roberson
2021 年 10 月 2 日
Do you mean "graph" in the sense of "graph theory" ? Nodes and edges ?
回答 (1 件)
Walter Roberson
2021 年 10 月 3 日
If you just have a collection of points in terms of coordinates, and there is no ordering or connections, then use scatter() . The 4th parameter can have one color for every point.
If you have a collection of vertices and edges, then use a graph() object and specify NodeColor when you plot() https://www.mathworks.com/matlabcentral/answers/477504-how-to-choose-different-colors-for-nodes#answer_388996
参考
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!