How can I format individual edges in a directed graph?
Show older comments
Hi all -
I am plotting a directed graph, however the formatting is really important to get right so I can achieve the objectives in my assignment. However, I would need to format each edge individually. An edge will have certain formats if a certain condition is met.
How do I get different edge layouts in the same graph and plot it? I am not finding this anywhere on the internet. Is this possible?
All the best.
6 Comments
Walter Roberson
on 1 Aug 2017
What kind of "formatting" is required? Color? Arrow style? Line width? Dash/dot pattern? Color range? Variable thickness? Line must take certain paths such as restricted to horizontal/vertical and 90 degree turns?
Felipe Schuback
on 2 Aug 2017
Walter Roberson
on 2 Aug 2017
highlight() allows you to control edgecolor and linewidth, but not arrow style.
Felipe Schuback
on 2 Aug 2017
Steven Lord
on 2 Aug 2017
See the documentation pages to which I linked in my Answer; they show how to use highlight and property manipulation to do what you're asking.
Felipe Schuback
on 2 Aug 2017
Accepted Answer
More Answers (0)
Categories
Find more on Graph and Network Algorithms in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!