plotly_density: Density plot using plotly

View source: R/density.R

plotly_densityR Documentation

Density plot using plotly

Description

Creates a density plot of all columns of a matrix or data.frame like structure.

Usage

plotly_density(mat, title = "", xlab = "", palette = viridis)

Arguments

mat

Matrix for column-wise kernel density estimate curves.

title

Plot title.

xlab

X axis label.

palette

Colour palette function (function that returns valid colour values, eg 'rainbow').

Value

A plotly htmlwidget

Examples

plotly_density(iris[, -5],
   title = "Density plot of Iris dataset",
   xlab = "Value")
mat <- matrix(rnorm(10000), ncol = 10)
plotly_density(mat)

Alanocallaghan/plotlyutils documentation built on May 3, 2023, 8:34 p.m.