phylotastic / datelife

R package containing datelife's core functionality
http://phylotastic.org/datelife/
13 stars 11 forks source link

allow tree grafting when n_overlap = 1 #61

Open LunaSare opened 6 years ago

LunaSare commented 6 years ago
taxa <- c("Chamaeleo Trioceros chapini", "Plectrurus canaricus", "Triticum pungens", "Microscalabotes", "Podallea madegassica", "Boarmia lunifera", "Bittium", "Lepidisis", "Puzosia rosarica", "Trechus ehlersi", "Psychotria griffithii", "Mulgedium spicatum", "Cyanopica", "Callicarpa heynii", "Exogyra robusta", "Schizomidae", "Fimbristylis scabra", "Phagnalon caroli", "Parmotrema pseudovirens", "Phortioecoides")
query <- make_datelife_query(input = taxa, get_spp_from_taxon = TRUE)
res <- get_datelife_result(input = query)

res contains 3 matrices, which overlap only by one taxon. res has two groves: the one with more taxa has one matrix only, the nest one has less taxa but has two trees. the grove with less taxa could be summarized with sdm or median, then grafted into the corresponding branch on the grove with more taxa.

This is a very simple example, but we could expand it to more complicated grove cases in order to get the most complete summary chronogram on each data set