Filter löschen
Filter löschen

How do I delete all annotations on a figure but not do clf?

62 Ansichten (letzte 30 Tage)
How do I delete all annotations on a Figure? I do not want to do "clf" since that loses attributes that I want to keep. Doing "cla" does not remove the annotations.

Akzeptierte Antwort

Ritesh Chandna
Ritesh Chandna am 10 Apr. 2017
Please use the below command to delete all the annotations on a figure:
>>delete(findall(gcf,'type','annotation'))
  2 Kommentare
John Pryce
John Pryce am 11 Apr. 2017
Thank you. Readable, works, and simpler than any other method I found.

Melden Sie sich an, um zu kommentieren.

Weitere Antworten (0)

Kategorien

Mehr zu MATLAB 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!

Translated by