function box(opt_box);
%BOX    Axis box.
%   BOX ON adds a box to the current axes.
%   BOX OFF takes if off.
%   BOX, by itself, toggles the box state.
%
%   BOX sets the Box property of the current axes.
%
%   See also GRID, AXES.

%   Copyright (c) 1984-98 by The MathWorks, Inc.
%   $Revision: 1.5 $  $Date: 1997/11/21 23:32:59 $

ax = gca;

if (nargin == 0)
    if (strcmp(get(ax,'Box'),'off'))
        set(ax,'Box','on');
    else
        set(ax,'Box','off');
    end
elseif (strcmp(opt_box, 'on'))
    set(ax,'Box', 'on');
elseif (strcmp(opt_box, 'off'))
    set(ax,'Box', 'off');
else
    error('Unknown command option.');
end
