dsm_plot: Off-diagonal Plotting Function for Dissimlarity Matricies

View source: R/dsm_plot.R

dsm_plotR Documentation

Off-diagonal Plotting Function for Dissimlarity Matricies

Description

This function will plot the off-diagonal elements of a dissmilarity matrix.

Usage

dsm_plot(dsm, col_n = 8, color_dir = 1, rev_fac = FALSE, melt = TRUE)

Arguments

dsm

a (dis)similarity matrix

col_n

number of colors used in palette

color_dir

direction of the color ramp. 1 == forward, -1 == reverse

rev_fac

logical indicating whether to reverse the factor level order

melt

logical indicating whether or not to melt the matrix into a data frame prior to plotting

Author(s)

Robert S. Chavez

Examples

cars_dsm <- 1-cor(mtcars)
dsm_plot(cars_dsm)

chavezlab/csnl documentation built on June 12, 2022, 10:09 a.m.