Correlation value plot
(Deprecated. See ggally_cor.)
ggally_cor_v1_5( data, mapping, alignPercent = 0.6, method = "pearson", use = "complete.obs", corAlignPercent = NULL, corMethod = NULL, corUse = NULL, displayGrid = TRUE, ... )
data |
data set using |
mapping |
aesthetics being used |
alignPercent |
right align position of numbers. Default is 60 percent across the horizontal |
method |
|
use |
|
corAlignPercent |
deprecated. Use parameter |
corMethod |
deprecated. Use parameter |
corUse |
deprecated. Use parameter |
displayGrid |
if TRUE, display aligned panel gridlines |
... |
other arguments being supplied to geom_text |
Estimate correlation from the given data.
Barret Schloerke
# Small function to display plots only if it's interactive
p_ <- GGally::print_if_interactive
data(tips, package = "reshape")
p_(ggally_cor_v1_5(tips, mapping = ggplot2::aes_string(x = "total_bill", y = "tip")))
# display with no grid
p_(ggally_cor_v1_5(
tips,
mapping = ggplot2::aes_string(x = "total_bill", y = "tip"),
displayGrid = FALSE
))
# change text attributes
p_(ggally_cor_v1_5(
tips,
mapping = ggplot2::aes(x = total_bill, y = tip),
size = 15,
colour = I("red")
))
# split by a variable
p_(ggally_cor_v1_5(
tips,
mapping = ggplot2::aes_string(x = "total_bill", y = "tip", color = "sex"),
size = 5
))Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.