R: Plot Method for Class 'lda'

plot.lda {MASS} | R Documentation

## Plot Method for Class 'lda'

### Description

Plots a set of data on one, two or more linear discriminants.

### Usage

    ## S3 method for class 'lda'
    plot(x, panel = panel.lda, ..., cex = 0.7, dimen,
         abbrev = FALSE, xlab = "LD1", ylab = "LD2")

### Arguments

`x` | An object of class `"lda"`.
`panel` | the panel function used to plot the data.
`...` | additional arguments to `pairs`, `ldahist` or `eqscplot`.
`cex` | graphics parameter `cex` for labels on plots.
`dimen` | The number of linear discriminants to be used for the plot; if this exceeds the number determined by `x` the smaller value is used.
`abbrev` | whether the group labels are abbreviated on the plots. If `abbrev > 0` this gives `minlength` in the call to `abbreviate`.
`xlab` | label for the x axis
`ylab` | label for the y axis

### Details

This function is a method for the generic function `plot()` for class `"lda"`. It can be invoked by calling `plot(x)` for an object `x` of the appropriate class, or directly by calling `plot.lda(x)` regardless of the class of the object.

The behaviour is determined by the value of `dimen`. For `dimen > 2`, a `pairs` plot is used. For `dimen = 2`, an equiscaled scatter plot is drawn. For `dimen = 1`, a set of histograms or density plots are drawn. Use argument `type` to match `"histogram"` or `"density"` or `"both"`.

### References

Venables, W. N. and Ripley, B. D. (2002) Modern Applied Statistics with S. Fourth edition. Springer.

### See Also

`pairs.lda`, `ldahist`, `lda`, `predict.lda`

[Package MASS version 7.3-35 Index]