tally {Correlplot} | R Documentation |
Create a tally on a biplot vector
Description
Function tally
marks of a set of dots on a biplot vector. It is thought for biplot vectors representing correlations,
such that their correlation scale becomes visible, without doing a full calibration with tick marks and tick mark labels.
Usage
tally(G, adj = 0, values = seq(-1, 1, by = 0.2), pch = 19, dotcolor = "black", cex = 0.5,
color.negative = "red", color.positive = "blue")
Arguments
G |
Matrix with biplot coordinates of the variables |
adj |
A scalar adjustment for the correlations |
values |
The values of the correlations to be marked off by dots |
pch |
The character code used for marking off correlations |
dotcolor |
The colour of the dots that are marked off |
cex |
The character expansion factor for a dot. |
color.negative |
The colour of the segments of the negative part of the correlation scale |
color.positive |
The colour of the segments of the positive part of the correlation scale |
Value
NULL
Author(s)
Jan Graffelman (jan.graffelman@upc.edu)
References
Graffelman, J. and De Leeuw, J. (2023) Improved approximation and visualization of the correlation matrix. The American Statistician pp. 1–20. doi:10.1080/00031305.2023.2186952
See Also
Examples
data(goblets)
R <- cor(goblets)
results <- eigen(R)
V <- results$vectors
Dl <- diag(results$values)
#
# Calculate correlation biplot coordinates
#
G <- crossprod(t(V[,1:2]),sqrt(Dl[1:2,1:2]))
#
# Make the biplot
#
bplot(G,G,rowch=NA,colch=NA,collab=colnames(R),
xl=c(-1.1,1.1),yl=c(-1.1,1.1))
#
# Create a correlation tally stick for variable X1
#
tally(G[1,])