1## Copyright (C) 1996, 1997, 2007, 2008, 2009 John W. Eaton
3## This file is part of Octave.
5## Octave is free software; you can redistribute it and/or modify it
6## under the terms of the GNU General Public License as published by
7## the Free Software Foundation; either version 3 of the License, or (at
8## your option) any later version.
10## Octave is distributed in the hope that it will be useful, but
11## WITHOUT ANY WARRANTY; without even the implied warranty of
12## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13## General Public License for more details.
15## You should have received a copy of the GNU General Public License
16## along with Octave; see the file COPYING. If not, see
17## <http://www.gnu.org/licenses/>.
20## @deftypefn {Function File} {} barh (@var{x}, @var{y})
21## @deftypefnx {Function File} {} barh (@var{y})
22## @deftypefnx {Function File} {} barh (@var{x}, @var{y}, @var{w})
23## @deftypefnx {Function File} {} barh (@var{x}, @var{y}, @var{w}, @var{style})
24## @deftypefnx {Function File} {@var{h} =} barh (@dots{}, @var{prop}, @var{val})
25## @deftypefnx {Function File} {} barh (@var{h}, @dots{})
26## Produce a horizontal bar graph from two vectors of x-y data.
28## If only one argument is given, it is taken as a vector of y-values
29## and the x coordinates are taken to be the indices of the elements.
31## The default width of 0.8 for the bars can be changed using @var{w}.
33## If @var{y} is a matrix, then each column of @var{y} is taken to be a
34## separate bar graph plotted on the same graph. By default the columns
35## are plotted side-by-side. This behavior can be changed by the @var{style}
36## argument, which can take the values @code{"grouped"} (the default),
37## or @code{"stacked"}.
39## The optional return value @var{h} provides a handle to the bar series
40## object. See @code{bar} for a description of the use of the bar series.
42## The optional input handle @var{h} allows an axis handle to be passed.
43## Properties of the patch graphics object can be changed using
44## @var{prop}, @var{val} pairs.
51function varargout = barh (varargin)
52 varargout = cell (nargout, 1);
53 [varargout{:}] = __bar__ (false, "barh", varargin{:});