'draw.beta' either draws a beta distribution with the specified parameters, or it returns the matrix of x and y values for plotting a beta distribution with the specified parameters.

ARGUMENTS:

'a' & 'b' are the parameters of a beta distribution.  If we sample from a binomial distribution whose parameter, theta, is sampled from a beta(1,1) prior (uniform distribution), and if we observe a - 1 successes and b - 1 failures, then the posterior distribution over theta is a beta(a, b) distribution.

'Xlim' is an optional paramter.  Use it to control the min & max values on the X-axis.

'Ymax' is an optional paramter.  Use it to control the maximum value on the Y-axis. 

'plot.dist = TRUE' to create a plot of the beta distribution; 

'plot.dist = FALSE' to return the x & y coordinates of the plot.

'Title = TRUE' to have a title on the plot that shows the parameters of the distribution.

'xlab', 'ylab': Labels for x and y axes.  Default to 'P(success)' and 'Probability Density', respectively.  

'Lty = 1' & 'Lwd = 2' are the default line type and line width on the plot (corresponding to the 'par' parameters, 'lty' & 'lwd'). An area is colored under the curve that corresponds to a credible interval for the binomial parameter if and only if 'plot.cred.int = TRUE'. The default value is 'plot.cred.int = FALSE'.  The following arguments only affect the plot if 'plot.cred.int = TRUE. 'cred.int' determines the level of the credible interval.  It defaults to 0.95.

'type.cred.int = 2' creates a two-tailed credible interval.  At present (4/4/2010), the code has not been written for plotting one-tailed credible intervals. The level of the credible interval is inserted in the colored area under the curve if and only if 'cred.lab = TRUE'. 'cred.col' determines the color used to color in the credible interval.

if 'cred.lab = TRUE', then a label for the credible interval is written to the plot.

'cred.col' controls the color of the area of the credible interval.

'Title = TRUE' if the the default title is added to the plot.

'xlab' and 'ylab' are the default axis labels.

'Lty' and 'Lwd' control the 'lty' and 'lwd' parameters of the plot.

'cex.axis' and 'cex.title' control the font size for the axis and title, respectively.  They default to 1.5 and 2, respectively.