Learn R Programming

corrViz (version 0.1.0)

corrBubble: corrBubble

Description

This function creates an interactive bubble plot of correlations between variables in a dataset.

Usage

corrBubble(
  mat,
  display = c("all", "upper", "lower"),
  pal = colorRampPalette(c("cornflowerblue", "white", "tomato"))(100)
)

Value

An interactive bubble plot displaying correlations.

Arguments

mat

A square correlation matrix to visualise.

display

A character vector specifying which part of the correlation matrix to display: 'all', 'upper', or 'lower', default is 'all'.

pal

A color palette for the bubble plot.

Details

Creates an interactive bubble plot displaying correlation values. By hovering mouse over a cell, the variables and correlation value is shown.

Examples

Run this code
cm <- cor(mtcars)

corrBubble(mat = cm,
           display = 'all')


Run the code above in your browser using DataLab