Learn R Programming

BioGeoBEARS (version 0.2.1)

binary_ranges_to_letter_codes: Convert binary presence/absence codes (1/0) to a list of text area names

Description

Given a row of a tipranges object, converts to a list of the corresponding statenames for each row.

Usage

binary_ranges_to_letter_codes(tipranges, areanames)

Arguments

tipranges
a tipranges object.
areanames
a list of the names of the areas

Value

letter_code_ranges A list of the states -- there will be as many states as there are rows/tips in tipranges. Each state will be a list of area names.

References

http://phylo.wikidot.com/matzke-2013-international-biogeography-society-poster https://code.google.com/p/lagrange/

Matzke_2012_IBS

See Also

binary_range_to_letter_code_list, letter_string_to_binary, letter_strings_to_tipranges_df, tipranges_to_tip_condlikes_of_data_on_each_state

Examples

Run this code
testval=1
# Define a tipranges object
tipranges_object = define_tipranges_object()
tipranges_object

areanames = getareas_from_tipranges_object(tipranges_object)
areanames

letter_code_ranges = binary_ranges_to_letter_codes(tipranges=tipranges_object,
areanames)
letter_code_ranges

Run the code above in your browser using DataLab