Info
Diese Frage ist geschlossen. Öffnen Sie sie erneut, um sie zu bearbeiten oder zu beantworten.
Im unable to get the coordinate locations of a node in a plotted graph....like if the node(124) is at the location (1,19) which is the x and y value of that node how do i get the x and y values for every node??
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen

The graph has an x and y axis....so provided that every node must correspond to a location....so how do u retrieve this location
0 Kommentare
Antworten (1)
Robert
am 30 Mär. 2016
If you provide additional details on how you generated that plot, this community might be better able to help you. As a starting point, you should look at the 'Children' of your axis. If they are lines, they will have 'XData' and 'YData' properties you can access. Try
myHandles = get(gca,'Children')
myLine = myHandles(1) % assuming it is a line
x = get(myLine,'XData');
y = get(myLine,'YData');
0 Kommentare
Diese Frage ist geschlossen.
Siehe auch
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!