If the two distributions being compared are similar, the points in the Q–Q plot will approximately lie on the identity line y = x.If the distributions are linearly related, the points in the Q–Q plot will approximately lie on a line, but not necessarily on the line y = x. Q–Q plots can also be used as a graphical means of estimating parameters in a location-scale family of distributions.[2][3] This can provide an assessment of goodness of fit that is graphical, rather than reducing to a numerical summary statistic.A more complicated construction is the case where two data sets of different sizes are being compared.[6] Many other choices have been suggested, both formal and heuristic, based on theory or simulations relevant in context.More generally, Shapiro–Wilk test uses the expected values of the order statistics of the given distribution; the resulting plot and line yields the generalized least squares estimate for location and scale (from the intercept and slope of the fitted line).However, this requires calculating the expected values of the order statistic, which may be difficult if the distribution is not normal.Alternatively, one may use estimates of the median of the order statistics, which one can compute based on estimates of the median of the order statistics of a uniform distribution and the quantile function of the distribution; this was suggested by Filliben (1975).These can be expressed in terms of the quantile function and the order statistic medians for the continuous uniform distribution by: where U(i) are the uniform order statistic medians and G is the quantile function for the desired distribution.The R programming language comes with functions to make Q–Q plots, namely qqnorm and qqplot from the stats package.The fastqq package implements faster plotting for large number of data points.
A normal Q–Q plot comparing randomly generated, independent standard normal data on the vertical axis to a standard normal population on the horizontal axis. The linearity of the points suggests that the data are normally distributed.
A Q–Q plot of a sample of data versus a
Weibull distribution
. The deciles of the distributions are shown in red. Three outliers are evident at the high end of the range. Otherwise, the data fit the Weibull(1,2) model well.
A Q–Q plot comparing the distributions of
standardized
daily maximum temperatures at 25 stations in the US state of Ohio in March and in July. The curved pattern suggests that the central
quantiles
are more closely spaced in July than in March, and that the July distribution is
skewed
to the left compared to the March distribution. The data cover the period 1893–2001.
Q–Q plot for first opening/final closing dates of
Washington State Route 20
, versus a normal distribution.
[
5
]
Outliers are visible in the upper right corner.