Learn R Programming

VarianceGamma (version 0.4-2)

VarianceGammaPlots: Variance Gamma Quantile-Quantile and Percent-Percent Plots

Description

qqvg produces a variance gamma Q-Q plot of the values in y.

ppvg produces a variance gamma P-P (percent-percent) or probability plot of the values in y. Graphical parameters may be given as arguments to qqvg and ppvg.

Usage

qqvg(y, vgC = NULL, sigma = NULL, theta = NULL, nu = NULL,
    param = c(vgC, sigma, theta, nu), main = "Variance Gamma Q-Q Plot",
    xlab = "Theoretical Quantiles", ylab = "Sample Quantiles",
    plot.it = TRUE, line = TRUE, ...)

ppvg(y, vgC = NULL, sigma = NULL, theta = NULL, nu = NULL, param = c(vgC, sigma, theta, nu), main = "Variance Gamma P-P Plot", xlab = "Uniform Quantiles", ylab = "Probability-integral-transformed Data", plot.it = TRUE, line = TRUE, ...)

Value

For qqvg and ppvg, a list with components:

x

The x coordinates of the points that are to be plotted.

y

The y coordinates of the points that are to be plotted.

Arguments

y

The data sample.

vgC

The location parameter \(c\), default is 0.

sigma

The spread parameter \(\sigma\), default is 1, must be positive.

theta

The asymmetry parameter \(\theta\), default is 0.

nu

The shape parameter \(\nu\), default is 1, must be positive.

param

An optional option, specifying the parameters as a vector which takes the form c(vgC,sigma,theta,nu) if known.

main

Plot title.

xlab, ylab

Plot labels.

plot.it

Logical. Should the result be plotted?

line

Add line through origin with unit slope.

...

Further graphical parameters.

Author

David Scott d.scott@auckland.ac.nz, Christine Yang Dong c.dong@auckland.ac.nz

Details

Users may specify the parameter values of the data sample y using argument param. If param is not specified by users, then the values are estimated from y by vgFit. For more details of fiting a variance gamma distribution to data, see vgFit.

References

Wilk, M. B. and Gnanadesikan, R. (1968) Probability plotting methods for the analysis of data. Biometrika. 55, 1--17.

See Also

ppoints, dvg.

Examples

Run this code

## Example 1: the parameter values are known
par(mfrow = c(1,2))
y <- rvg(200, param = c(2,2,1,2))
qqvg(y, param = c(2,2,1,2),line = FALSE)
abline(0, 1, col = 2)
ppvg(y, param = c(2,2,1,2))

## Example 2: the parameter values are unknown
par(mfrow = c(1,2))
y <- rvg(200, param = c(2,2,1,2))
qqvg(y, line = FALSE)
abline(0, 1, col = 2)
ppvg(y)

Run the code above in your browser using DataLab