Description Usage Arguments Details Value See Also Examples
Make a quantile comparison plot (qq-plot) for each subset of groups separately using ggplot2 graphics.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 |
y |
(formula|numeric|character)
Either a formula, a numeric vector or a name of a vector
in |
data |
A data frame that contains the variables mentioned in |
distribution |
root name of comparison distribution – e.g., |
... |
Parameters to be passed to function, selected in |
line |
(string) A parameter, that controls how reference line is drawn. Options:
|
envelope |
(numeric | |
method |
(string:
|
groups |
( |
use_colors |
(logical) use colors for multiple groups |
scales |
("free"|"free_x"|"free_y"|"fixed")
a parmeter to be passed to
|
sep |
(character)
Group name separator if more than one grouping variable is used.
default is |
Function qq_plot
is inspired by qqPlot()
in package car
(writen by J. Fox).
A ggplot2
object
car::qqPlot()
from car package,
stats::qqplot()
from stats package.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 | library(biostat)
data(iris)
# Formula (no groups):
qq_plot(~Sepal.Length, data = iris)
qq_plot("Sepal.Length", data = iris)
# Formula (several groups):
qq_plot(Sepal.Length ~ Species, data = iris)
qq_plot(Sepal.Length ~ Species, data = iris, envelope = 0.90)
# Formula (several groups in colors):
qq_plot(Sepal.Length ~ Species, data = iris, use_colors = TRUE)
# Vectors (several groups):
qq_plot(iris$Sepal.Length, groups = iris$Species)
# For one group:
qq_plot("Sepal.Length", data = iris)
qq_plot(~Sepal.Length, data = iris)
qq_plot(iris$Sepal.Length)
# Other examples
qq_plot(~weight, data = chickwts)
qq_plot(weight ~ feed, data = chickwts)
qq_plot(uptake ~ Type + Treatment, data = CO2)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.