fortify.renyiaccum: Fortify Rényi accumulation curves

fortify.renyiaccumR Documentation

Fortify Rényi accumulation curves

Description

Prepares a fortified version of results from vegan::renyiaccum() objects.

Usage

## S3 method for class 'renyiaccum'
fortify(model, data, ...)

Arguments

model

an object of class vegan::renyiaccum().

data

original data set. Currently ignored.

...

additional arguments passed to other methods. Ignored in this method.

Value

A data frame (tibble) is returned. What is returned depends on how vegan::renyiaccum() was called. If raw = FALSE, then a data frame with columns site, scale, mean, std_dev, min, max, q2.5, and q97.5, containing the accumulated sites, the Rényi scale, and summary statistics of the Rényi accumulation curves. An additional column collector will be present if collector = TRUE was used in the vegan::renyiaccum() call. If raw = TRUE, then a data frame with columns site, permutation, scale, and diversity, containing the site and permutation identifiers, Rényi scale, and the Rényi diversity, respectively.

Author(s)

Gavin L. Simpson much rewritten from an original by Didzis Elferts.

Examples

library("ggplot2")
data(BCI)
pool <- renyiaccum(BCI)
df <- fortify(pool)
df

ggplot(df, aes(x = site, y = mean)) +
    geom_ribbon(aes(ymin = q2.5, ymax = q97.5, x = site),
                alpha = 0.2, inherit.aes = FALSE) +
    geom_line() +
    facet_wrap(~ scale)

gavinsimpson/ggvegan documentation built on June 12, 2025, 7:39 p.m.