Plotting points and lines
2 次查看(过去 30 天)
显示 更早的评论
Hello
I would like to plot these edges and figures as shown in these images. I am able to do it manually using gplot using the following lines code for each one of the figure. But it is time consuming and lot of manual work since I have a lot of these figures to plot (over 50).
G = [0,0,0,0,0; 0,0,1,0,0; 0,0,0,0,1; 0,0,0,0,0; 0,0,0,0,0];
xy = [ 5 10; 0 5; 5 1 ; 10 7.5; 10 2.5];
gplot(G,xy,'-o');
axis([0 75 0 75]) % To Center the Figure
Is there any better way to do this or would you recommend any other tool or software.
Also as you can see, there are two lines between two points. like in the nodes_required jpeg figure, but unfortunately I cannot do this in matlab as well. Is there a way to do this or another possibility could be to use different colours for two lines , three lines and so on.
Thanks in advance
3 个评论
Guillaume
2014-11-21
Does your data come as an adjacency matrix? If so, how do you decide which edges have a double line? If not, how is it represented?
采纳的回答
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Annotations 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!