Get the maximum rangesize for a given ancestral rangesize

Share:

Description

This function returns the maximum descendant rangesize for a given ancestral rangesize, given a list of 0/1 values specifying the possibility of each descendant rangesizes.

Usage

1
  maxsize(areasizes_possible_01)

Arguments

areasizes_possible_01

A list of 0/1 values, indicating whether an range of that size (rangesize = 1-based index = 1, 2, 3...) is possible (1) or not (0).

Details

This is mostly a utility function used within apply within other functions.

Value

max_number_of_areas The maximum number of areas

Note

Go BEARS!

Author(s)

Nicholas J. Matzke matzke@berkeley.edu

References

http://phylo.wikidot.com/matzke-2013-international-biogeography-society-poster

Matzke_2012_IBS

See Also

apply

Examples

1
2
3
testval=1
areasizes_possible_01 = c(1,1,1,0,0)
maxsize(areasizes_possible_01)

Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.