How do i insert the area of each shape in the centre of it?
5 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Yashlin Naidoo
am 19 Mai 2015
Bearbeitet: Yashlin Naidoo
am 30 Mai 2015
This is my code below :
0 Kommentare
Akzeptierte Antwort
Image Analyst
am 19 Mai 2015
Use sprintf() to create a string with the area in it. Then use text() to place it in the axes
caption = sprintf('Area = %.1f', area);
text(x, y, caption);
Of course you need to figure out what x and y are to position the string in the best looking spot.
8 Kommentare
Image Analyst
am 25 Mai 2015
Not sure what you mean. To get every triangle, or just any triangle in general, you have to make the x and y have the coordinates of the three vertices. But I'm sure you know that already , so I'm not really sure what the question is.
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Annotations finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!