Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

peeledHull

peeledHull


Description

Computes and plots a peeled hull around a set of points onto a current graphics device.

Usage

peeledHull(data_matrix, x_axis = 1, y_axis = 2, percentage = 1, 
	col = "black", lwd = 3, lty = 1)

Arguments

data_matrix

A set of data you would like to plot on 2 dimensions (e.g., a scatter plot). Can be original data or factor scores or anything with at least 2 columns.

x_axis

Which axis is the x-axis? Default is 1.

y_axis

Which axis is the y-axis? Default is 2.

percentage

The percentage of points that should be enveloped by the hull.

col

The color of the hull (see col in plot()).

lwd

The thickness of the hull line (see lwd in plot())

lty

The line type (see lty in plot()).

Note

The code for this function was (barely) adapted from Michael Greenacre's book on correspondence analysis. All credit for this code should go to Michael Greenacre; I only turned it into a function. The original code can be found at http://carme-n.org/?sec=code2

Author(s)

Derek Beaton turned Michael Greenacre's code into a function.

References

Greenacre, M. J. (2007). Correspondence Analysis in Practice. Chapman and Hall.


prettyGraphs

Publication-Quality Graphics

v2.1.6
GPL-2
Authors
Derek Beaton
Initial release
2018-12-17

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.