Learn R Programming

fwtraits (version 1.0.0)

fw_fdendro: For computing the functional dendogram

Description

For computing the functional dendogram

Usage

fw_fdendro(fwdata, method = "average", k = 4, plot = FALSE)

Value

dataframe, plot

Arguments

fwdata

list A list from the fw_fetchdata function is the only data type accepted.

method

string Clustering method, including ward, average, and complete

k

integer Determine the number of cluster the user wants to output after data clustering. The default is 4.

plot

logical Either TRUE to show the plot of functional dendogram. Defualt is FALSE.

Examples

Run this code

if (FALSE) {
  fishtraits <- fw_fetchdata(data = speciesdata,
                        ecoparams = c('rheophily habitat', 'spawning habitat',
                        'feeding diet adult'),
                        taxonomic_column = 'scientificName',
                        organismgroup = 'fi')


 head(fdendoclust, 3)

 table(fdendoclust$cluster)

}

Run the code above in your browser using DataLab