I need to plot multiple circles using the built in rectangle function. I have matrices that contain the x and y coordinates of the points that I want the center of my circle to be on. d is the diameter of the circles. The code I am using is below. I want to plot the circles without using the for loop in order to save time.
for i = 1 : size(x,1)pos = [x(i)-d/2, y(i)-d/2, d, d];rectangle('Position',pos,'Curvature',[1 1],'FaceColor','c','EdgeColor','k','LineWidth',1);end
Best Answer