sRMatTemp = [SENSORRANGE];
sRMat = repmat(sRMatTemp, size(obj.landmarks.sensed(:,1), 1));
ellipse(((2*pi*sRMat)/(360/obj.landmarks.sensed(:,4))), obj.landmarks.sensed(:,5) , obj.landmarks.sensed(:,3), obj.landmarks.apparentPositionsST(:,1), obj.landmarks.apparentPositionsST(:,2));
The above code works fine... ONCE. The problem is I need to animate it. Every time I plot the ellipses, they stay on my screen and the graph becomes unreadable instantly.
This is the code above that works fine as well, to animate a scatter plot. Is there a way I can use this with ellipses somehow?
I'm using ellipse.m that's on the Mathworks community site.
fig=figure;
axes('NextPlot','add');
set(fig, 'name', 'Animated Graph')
l.st=scatter([0],[0],'g.');
set(l.st,'XData',obj.landmarks.apparentPositionsST(:,1),'YData',obj.landmarks.apparentPositionsST(:,2));
drawnow