Skip to contents

A set of pre-defined functions for sample_statistics.

Usage

default_stats()

Value

A named list of functions/purrr-style lambdas

Examples

default_stats()
#> $sum
#> ~sum(.x, na.rm = TRUE)
#> <environment: 0x5575f0687938>
#> 
#> $count
#> function (x)  .Primitive("length")
#> 
#> $shannon
#> ~vegan::diversity(.x, index = "shannon")
#> <environment: 0x5575f0687938>
#> 
#> $simpson
#> ~vegan::diversity(.x, index = "simpson")
#> <environment: 0x5575f0687938>
#> 
#> $invsimpson
#> ~vegan::diversity(.x, index = "invsimpson")
#> <environment: 0x5575f0687938>
#> 
#> $describe
#> ~tibble::as_tibble(psych::describe(.x))
#> <environment: 0x5575f0687938>
#>