Three-dimensional horizontal bar plot.
bar3h(x,y, options)
x An array of real numbers.
y An array of real numbers.
options A set of options to control the appearance of the plot. One of the options may be specified as the string 'stacked' or 'grouped' for stacking or grouping multiple bars. The other option may be used to specify the width of the plot in the form of a pair 'width', w , where w is the width parameter, a number between 0 and 1 .

If x is a one-dimensional array, bar3h(x) displays horizontal hexadra in the x-z plane with rectangular faces (three-d bars) at the points [1,2,..n] along the z-axis, where n is the number of elements in x . The width of the bars is proportional to the magnitudes of the elements of x .

If x has m columns, bar3h(x) displays m rows horizontal bars, the other at each of the points [1,2,..n] where n is the number of rows in x , with each row located along the third dimension (y-axis). If one of the options is the string 'stacked' or 'grouped' , all the bars are placed in a single row, with the bars at each point [1,...n] stacked vertically one over the other or placed side by side with the heights of the bars determined by the elements in a given row of x .

The distance between the bars at adjoining points on the z-axis can be controlled by specifying the width parameter in the input options . If width is specified to be one, there is no gap between the bars at various points, and if it is zero, bars are displayed with maximum possible gaps between them. Intermediate values of the width parameter control the width of gaps accordingly.

In the call bar3h(x, y) , the height of the bars is specified by the elements of y , and elements of x are used for the locations of the bars along the x-axis. The inputs specified in options control the gap size and the type of grouping of bars just as for the call bar3h(x) .
>>title("Bar Plot")
>>title("Grouped Bar Plot")
>>title("Stacked Bar Plot")
>>title("Bar Plot with Specified Fractional Width")