qqPlot
QuantileQuantile Plots for various distributions
qqPlot
creates a QQ plot of the values in x including a line which passes through the first and third quartiles.
 Keywords
 Distribution Identification, Six Sigma
Usage
qqPlot(x, y, confbounds = TRUE, alpha, main, xlab, ylab, xlim, ylim, border = "red", bounds.col = "black", bounds.lty = 1, start, ...)
Arguments
 x
 the sample for qqPlot
 y

character string specifying the distribution of x. The function
qqPlot
will support the following character strings fory
: “beta”
 “cauchy”
 “chisquared”
 “exponential”
 “f”
 “gamma”
 “geometric”
 “lognormal”
 “lognormal”
 “logistic”
 “negative binomial”
 “normal”
 “Poisson”
 “t”
 “weibull”
By default
distribution
is set to “normal”.  confbounds
 boolean value: ‘TRUE’ if confidence bounds should be drawn (default value).
 alpha
 significance level for the confidence bounds, set on ‘0.05’ by default.
 main

an overall title for the plot: see
title
.  xlab

a title for the x axis:
title
.  ylab

a title for the y axis:
title
.  xlim
 vector giving the range of the xaxis.
 ylim
 vector giving the range of the yaxis.
 border

numerical value or single character string giving the color of interpolation line.
By default
border
is set to “red”.  bounds.col
 numerical value or single character string giving the color of confidence bounds lines. By default bounds is set to “black”.
 bounds.lty
 numerical value giving the color of confidence bounds lines. By default bounds is set to ‘1’.
 start
 A named list giving the parameters to be fitted with initial values. Must be supplied for some distribution: (see Details).
 ...

further graphical parameters: (see
par
).
Details
Distribution fitting is deligated to function fitdistr
of the Rpackage MASS.
For computation of the confidence bounds the variance of the quantiles is estimated using the delta method,
which implies estimation of observed Fisher Information matrix as well as the gradient of the CDF of the fitted distribution.
Where possible, those values are replaced by their normal approximation.
Value

a list containing the x and y quantiles
 x
 sample quantiles
 y
 theoretical quantiles
Note
For an example in context which shows the usage of the function qqPlot()
please read the vignette for the package qualityTools
at http://www.rqualitytools.org/html/Analyze.html.
See Also
ppPlot
fitdistr
in Rpackage MASS
http://www.rqualitytools.org/html/Analyze.html
Examples
#set up the plotting window for 6 plots
par(mfrow = c(3,2))
#generate random data from weibull distribution
x = rweibull(20, 8, 2)
#QuantileQuantile Plot for different distributions
qqPlot(x, "lognormal")
qqPlot(x, "normal")
qqPlot(x, "exponential", DB = TRUE)
qqPlot(x, "cauchy")
qqPlot(x, "weibull")
qqPlot(x, "logistic")