plot method for objects inheriting from class "anscombe".

# S3 method for anscombe
plot(x, input = FALSE, stats = TRUE, digits = 3, legend_args = list(), ...)

Arguments

x

an object of class 'anscombe', a result of a call to anscombise or mimic.

input

A logical scalar. Should the old, input data, that is, the Anscombe's dataset chosen for anscombise or the argument x2 to mimic, be plotted? If old = FALSE then the new, output data are plotted. If old = TRUE then the old data are plotted.

stats

A logical scalar. Should the sample summary statistics n, means, variances and correlation be added to the plot?

digits

An integer. The argument digits passed to signif to round the values of the statistics before adding them to the plot.

legend_args

A list of arguments to be passed to legend when stats = TRUE, especially legend_args$x to control the position of the legend.

...

Further arguments to be passed to plot

Value

Nothing is returned.

Details

This function is only applicable in 2 dimensions, that is, when length(attr(x, "new_stats")$means) = 2.

Examples

See the examples in anscombise and mimic.

See also