plotting lines as separate objects
Ältere Kommentare anzeigen

Hi Guys, I am new to matlab and I am trying to plot the following points. The first column represents x values and the second column represents y values. If I plot(x,y), matlab plots all the points as one continuous line. But what I want is different lines separated by the NaN like shown above. For example, I want first four (x,y) points to be one separate line, the next three (x,y) points to be another line and so on... I want to plot these lines separately because I need to find the centroid of each lines (actually these are curves).
Can anyone help, please?
Thank you!
Akzeptierte Antwort
Weitere Antworten (0)
Kategorien
Mehr zu MATLAB finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!