daisie_data_to_tables: Convert 'daisie_data' into a tabular format

View source: R/daisie_data_to_tables.R

daisie_data_to_tablesR Documentation

Convert daisie_data into a tabular format

Description

Convert daisie_data into a tabular format.

Usage

daisie_data_to_tables(daisie_data)

Arguments

daisie_data

a DAISIE datalist, as can be checked by check_daisie_data. To quote the DAISE doc:

A datalist is an object containing information on colonisation and branching times. This object can be generated using DAISIE_dataprep, which converts a user-specified data table into a datalist, but the object can of course also be entered directly.

A datalist is a list with the following elements:

The first element of the list has two or three components:

  • $island_age - the island age

Then, depending on whether a distinction between types is made, we have:

  • $not_present - the number of mainland lineages that are not present on the island

or:

  • $not_present_type1 - the number of mainland lineages of type 1 that are not present on the island

  • $not_present_type2 - the number of mainland lineages of type 2 that are not present on the island

The remaining elements of the datalist each contains information on a single colonist lineage on the island and has 5 components:

  • $colonist_name - the name of the species or clade that colonized the island

  • $branching_times - island age followed by stem age of the population/species in the case of Non-endemic, Non-endemic_MaxAge species and Endemic species with no close relatives on the island. For endemic clades with more than one species on the island (cladogenetic clades/ radiations) these should be island age followed by the branching times of the island clade including the stem age of the clade

  • $stac - the status of the colonist, see stac_to_str for values and descriptions

  • $missing_species - number of island species that were not sampled for particular clade (only applicable for endemic clades)

  • $type1or2 - whether the colonist belongs to type 1 or type 2

Details

DAISIE and DAISIEmailand data is messy and contains multiple instances of data duplication, due to, among others, historical reasons.

This function reduces the island history to tidy data without duplicates.

Value

a list with these elements:

  • header: general parameters of the results see daisie_header_to_table

  • branching_times: the branching times

  • colonists_general: general info of each clade see daisie_data_colonist_info_to_general_table

  • colonists_branching_times: branching times per clade see daisie_data_colonist_info_to_braching_times_table

  • colonisation_times: times that the colonisations took place

Author(s)

Richèl J.C. Bilderbeek


joshwlambert/DAISIEmainland documentation built on July 14, 2024, 5:40 p.m.