Clear Filters
Clear Filters

Change pzplot marker size

51 views (last 30 days)
RuiQi
RuiQi on 1 Apr 2016
Answered: Stephen Wilkerson on 12 Jun 2023
Hello,
How do i change the marker size for the pzplot ?

Accepted Answer

Azzi Abdelmalek
Azzi Abdelmalek on 1 Apr 2016
h=tf(1,[1 1 5])
pzplot(h)
findobj(gca,'type','line')
set(a(2),'markersize',7)
set(a(3),'markersize',7)
  3 Comments
David Willis
David Willis on 18 May 2017
In Version 2013a I had to make a small modification to the code above. I also added a line to show how to change the marker linewidth.
a = findobj returns an array of double. In the case below, a(3) points to all the pole markers, a(2) to the zero markers. The for loop is a lazy man way of getting them all.
h=tf([1 2],[1 1 5])
pzplot(h)
a = findobj(gca,'type','line')
for i = 1:length(a)
set(a(i),'markersize',12) %change marker size
set(a(i), 'linewidth',2) %change linewidth
end
Kamilu Sanusi
Kamilu Sanusi on 2 May 2023
@Azzi Abdelmalek, if i am plotting eigen values of more than one matrix, and I want to change the pole and zero of markers for each matrix on the same pz plot, please how do i make changes? I am more of concern with the thickness (boldness) of the marker than the size
if D == 15
pzmap(T,'r')
end
hold on
if D == 25
pzmap(T,'m')
end
Thank you

Sign in to comment.

More Answers (1)

Stephen Wilkerson
Stephen Wilkerson on 12 Jun 2023
% Let's change the symbol size
% Why Mathworks makes the symbols unseeable is beyond me
% Why mathworks makes this harder then it should be is beyond me
% Here is a solution that works, unlike the above!
sys1 = tf(4,[1 0 4]);
h = pzplot(sys1)
grid on
a = findobj(gca,'type','line');
for i = 1:length(a)
set(a(i),'markersize',20); %change marker size
set(a(i), 'linewidth',2); %change linewidth
set(a(i),'Color','r')
end

Categories

Find more on Matrices and Arrays in Help Center and File Exchange

Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!