Assign species to a priori groupings.

create_groups(dat.obj, species.groups = NULL, abbrev = FALSE)

Arguments

dat.obj

Input dataset. Must be an object of class brsdata, as returned by read_data or simulate_data.

species.groups

List indicating which species should be grouped. These can be given using any combination of scientific name, common name, or unique identifier, as defined in species_brs. If species.groups is given as a named list, the names of each list element will be used as group names. If species.groups is unnamed, the function will combine species codes from species_brs to generate appropriate group names.

abbrev

Logical. If TRUE, group names will be abbreviated. This is useful for plotting and data summaries.

Value

A list object of class brsdata.grp.

See also

Author

Phil J. Bouchet

Examples