function dummy = optlims(Editor)
%OPTLIMS  Derive desirable X/Y limits for root locus plot.

%   Author(s): P. Gahinet
%   Copyright 1986-2000 The MathWorks, Inc. 
%   $Revision: 1.2 $ $Date: 2000/06/14 20:21:49 $

% REVISIT
dummy = [];

% Determine desirable limits for root locus
[Xlim,Ylim] = rloclims(Editor.LocusRoots,getTs(Editor.LoopData));
   
% Make sure to include closed-loop poles (red squares)
% REVISIT: merge next two
R = Editor.ClosedPoles;
[XlimS,YlimS] = rloclims(1.2*R(isfinite(R),:),0);
Xlim(1) = floor(min(Xlim(1),XlimS(1)));
Xlim(2) = ceil(max(Xlim(2),XlimS(2)));
Ymax = ceil(max(Ylim(2),YlimS(2)));

% Store optimal limits
Editor.XlimOpt = Xlim;
Editor.YlimOpt = [-Ymax,Ymax];

