plotCorrelation: Plot Correlation Matrix

View source: R/plotCorrelation.R

plotCorrelationR Documentation

Plot Correlation Matrix

Description

This function takes a result dataframe from betaStability() and creates a faceted scatter plot matrix to visualize correlations between different stability quantification methods.

Usage

plotCorrelation(data, method = "spearman")

Arguments

data

A dataframe containing stability results from betaStability(). Must have at least 2 numeric columns.

method

Correlation method to use. Default is "spearman". Other options include "pearson" and "kendall".

Value

A ggplot2 plot object showing pairwise correlations between columns.

Examples

library(vegan)
library(ggplot2)
data(varespec)
data(varechem)
results <- betaStability(
    comtable = varespec,
    envmeta = varechem,
    method = c("linearPred", "mlPred", "glmPred")
)
plotCorrelation(results)


betaStability documentation built on June 5, 2026, 5:08 p.m.