| indexplot | R Documentation |
Index Plots
indexplot(
x,
groups,
labels = seq_along(x),
id.method = "y",
type = "h",
id.n = 0,
ylab,
legend = "topright",
title,
col = palette(),
...
)
x |
a numeric variable, a matrix whose columns are numeric variables, or a numeric data frame; if |
groups |
an optional grouping variable, typically a factor (or character or logical variable). |
labels |
point labels; if |
id.method |
method for identifying points; see |
type |
to be passed to |
id.n |
number of points to identify; see |
ylab |
label for vertical axis; if missing, will be constructed from |
legend |
see |
title |
title for the legend; may normally be omitted. |
col |
vector of colors for the |
... |
to be passed to |
Index plots with point identification.
Returns labelled indices of identified points or (invisibly) NULL if no points are identified or if there are multiple variables with some missing data.
John Fox
showLabels, plot.default
with(Prestige, indexplot(income, id.n=2, labels=rownames(Prestige)))
with(Prestige, indexplot(Prestige[, c("income", "education", "prestige")],
groups = Prestige$type, id.n=2))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.