Creator
Creator

Reputation: 43

Difference in "polar" command in Matlab from 2013 version to 2015

I wanted to remove the numbers from the polar plot so I used the following:

myline = polar(txxx, pxxx); get handle of the data line
set(0,'Showhiddenhandles','on') % to show hidden handles
extrastuff = setdiff(get(gca,'children'),myline);
delete(extrastuff)

and it works in 2013b version but does not work in 2015 version. Can anyone help me to do the same in 2015 version.

Upvotes: 1

Views: 132

Answers (1)

Luis Mendo
Luis Mendo

Reputation: 112689

The polar function creates those text objects with their 'HandleVisibility' set to 'off', so you can't see them from outside the function.

You can use a modified version of polar as follows:

  1. Open file polar.m.
  2. Find all lines that include text(. Those are the lines that create the text objects.
  3. Comment out those lines, as well as their continuations.
  4. Save the file with a different name, for example polar2.m.

Upvotes: 1

Related Questions