Generate a sample of species, weighted by their score

generate_sample(taxon_scores, ntax, phy, pd_weighting, min.prob = 0.01,
  max.prob = 0.99)

Arguments

taxon_scores

The vector of scores for taxa

ntax

The number of taxa you want returned

phy

Phylogeny to prune

pd_weighting

How much to weight the pd vs the popularity

min.prob

The minimum probability of sampling for a taxon

max.prob

The maximum probability of sampling for a taxon

Value

A list: selected=vector of names of sampled taxa to include, and score=sum of the taxon metrics for these taxa