The tips between divergent nodes or fixation mutations on the lineages are each gathered as group.

groupTips(tree, ...)

# S3 method for phyMSAmatched
groupTips(
  tree,
  similarity = NULL,
  simMatrix = NULL,
  forbidTrivial = TRUE,
  tipnames = TRUE,
  ...
)

# S3 method for lineagePath
groupTips(tree, tipnames = TRUE, ...)

# S3 method for sitesMinEntropy
groupTips(tree, tipnames = TRUE, ...)

# S3 method for fixationSites
groupTips(tree, tipnames = TRUE, ...)

# S3 method for fixationPath
groupTips(tree, tipnames = TRUE, ...)

Arguments

tree

The return from addMSA, lineagePath, sitesMinEntropy or other functions.

...

Other arguments.

similarity

This decides how minor SNPs are to remove. If provided as fraction between 0 and 1, then the minimum number of SNP will be total tips times similariy. If provided as integer greater than 1, the minimum number will be similariy. The default similariy is 0.05 for lineagePath.

simMatrix

Deprecated and will not have effect.

forbidTrivial

Does not allow trivial trimming.

tipnames

If return tips as integer or tip names.

Value

groupTips returns grouping of tips.

Examples

data(zikv_tree)
data(zikv_align)
tree <- addMSA(zikv_tree, alignment = zikv_align)
groupTips(tree)
#> $`363`
#>  [1] "ANK57896" "AMD61711" "AQS26698" "APG56458" "AUI42289" "AMR39834"
#>  [7] "AWH65848" "APO08504" "AMX81917" "AVZ47169" "AMX81916" "AMD61710"
#> [13] "AMK49492" "AMX81915" "AOC50652" "APH11611" "BBC70847" "AUF35022"
#> [19] "ATL14618" "AUF35021"
#> 
#> $`513`
#>  [1] "APG56499" "ASW34302" "AOL02459" "APH11552" "APH11574" "APH11550"
#>  [7] "APH11586" "APH11535" "APH11544" "AWK27349" "APH11584" "APH11567"
#> [13] "APH11548" "APH11572" "APH11575" "APH11568" "APH11561" "APH11533"
#> [19] "APH11523" "APH11545" "APH11554" "APH11553" "APH11558" "APH11564"
#> [25] "APH11509" "APH11537" "APH11521" "APH11555" "APH11577" "APH11525"
#> [31] "APH11570" "APH11565" "APH11541" "APH11583" "APH11501" "APH11524"
#> [37] "APH11505" "APH11546" "APH11582" "APH11585" "APH11557" "APH11579"
#> [43] "APH11540" "APH11495" "AOO19565" "APH11511" "APH11547" "APH11542"
#> [49] "APH11563" "APH11504" "APH11587" "APH11569"
#> 
#> $`567`
#>  [1] "APH11580" "APH11576" "APH11531" "APH11593" "APH11517" "APH11527"
#>  [7] "APH11530" "APH11590" "APH11559" "APH11592" "APH11594" "APH11532"
#> [13] "APH11518" "APH11549" "APH11512" "APH11514" "APH11515" "APH11581"
#> [19] "APH11508" "APH11516" "APH11538" "APH11551" "APH11571" "APH11566"
#> [25] "APH11529" "APH11543" "APH11573" "APH11560" "APH11536" "APH11493"
#> [31] "APH11528" "APH11562" "APH11595"
#> 
#> $`556`
#>  [1] "AVG19202" "APH11539" "APH11534" "APH11500" "APH11502" "APH11503"
#>  [7] "APH11578" "APH11499" "APH11498" "APH11506" "APH11507" "APH11497"
#> 
#> $`493`
#> [1] "AVV62004" "BAX00477"
#> 
#> $`610`
#>  [1] "BAV89190" "AOI20067" "AMM43325" "AMM43326" "ANC90425" "AUI42329"
#>  [7] "AUI42330" "AMR68932" "ANF16414" "AMT75536" "AMV49165" "AMO03410"
#> [13] "ANA12599" "AMM39806" "AMR39830"
#> 
#> $`489`
#>  [1] "ANO46307" "AVG19275" "ANN44857" "ANO46306" "ANO46309" "ANO46305"
#>  [7] "ANO46303" "ANO46302" "ANO46301" "ARB08102" "AHZ13508" "ANO46304"
#> [13] "ANO46308" "AMD16557"
#> 
#> $`402`
#> [1] "ALX35659" "APY24198" "APO36913" "ANQ92019" "AOX49264" "AOX49265"
#> 
#> $`400`
#>  [1] "APY24199" "AMH87239" "AMA12086" "AMA12085" "AMU04506" "AMA12087"
#>  [7] "AMA12084" "AML81028" "AOY08518" "ARB07962" "AOY08538" "AOG18295"
#> [13] "AOY08517" "AOY08541" "AMM39805" "ARX97119" "AMK79468" "AML82110"
#> [19] "AMR39831" "AMX81918" "APY24200" "AOO19564" "AUI42194" "AOG18296"
#> [25] "ATG29267" "AQX32985" "AQZ41948" "AQZ41954" "AOY08533" "ASL68978"
#> [31] "AQZ41953" "AQZ41947" "AVZ25033" "ATG29291" "ATG29301" "ASL68979"
#> [37] "ATG29299" "AQZ41949" "AQZ41950" "AQZ41951" "ATI21641" "ANO46297"
#> [43] "ANO46298" "APO08503" "ANG09399" "ARU07183" "AQZ41956" "ATG29276"
#> [49] "AOW32303" "ATG29292" "ATG29295" "AOY08536" "ASL68974" "AMQ48986"
#> [55] "ATG29315" "ATG29307" "ATG29270" "AOC50654" "AMC13913" "AMC13912"
#> [61] "APO39243" "APO39229" "AQZ41952" "AQZ41955" "ARI68105" "ASU55505"
#> [67] "AQM74762" "AUD54964" "ART29828" "AWF93617" "APC60215" "ATG29306"
#> [73] "ATG29284" "AQM74761" "ATG29287" "ATG29303" "AWF93619" "AWF93618"
#> 
#> $`472`
#>  [1] "AMK49165" "ARB07976" "APB03018" "AMC13911" "APB03019" "ASU55416"
#>  [7] "ANK57897" "AWH65849" "ASU55417" "ANW07476" "AMZ03556"
#> 
#> $`628`
#>  [1] "ARU07074"     "AMX81919"     "AMB37295"     "ANC90426"     "ALU33341"    
#>  [6] "ASB32509"     "ARU07076"     "ATB53752"     "AOR82893"     "ARU07075"    
#> [11] "AMQ48982"     "AMK49164"     "APG56457"     "ANH10698"     "AOR82892"    
#> [16] "AMB18850"     "YP_009428568" "ART29823"     "ASK51714"     "ARB07953"    
#> [21] "AOY08537"     "AOY08523"     "ASW34087"     "AOS90224"     "BAV82373"    
#> [26] "ART29826"     "ART29825"     "AOY08525"     "AOY08535"     "APW84875"    
#> [31] "APW84874"     "APW84873"     "APW84876"     "ANH22038"     "APW84877"    
#> [36] "APW84872"     "AMN14620"     "AVZ25035"     "AOY08542"     "ARB07932"    
#> [41] "AOS90223"     "AOS90220"     "APO39232"     "APO39233"     "AOO85388"    
#> [46] "AOO53981"     "AOS90222"     "APO39228"     "AOS90221"     "AOY08546"    
#> [51] "AOY08521"     "AOY08516"     "APB03021"     "APO39236"     "APO39237"    
#> [56] "APB03020"    
#> 
#> $`409`
#>  [1] "AQU12485" "AMQ48981" "APH11492" "AOO54270" "AND01116" "AMS00611"
#>  [7] "ARB07967" "ANF04752" "AOE22997" "ASU55403" "ASU55393" "ANB66184"
#> [13] "AMC33116" "ASU55400" "ASU55409" "AMQ34003" "AMQ34004" "AMM39804"
#> [19] "ASU55411" "ASU55395" "AMZ03557" "APQ41784" "ASU55391" "ASU55396"
#> [25] "ASU55392" "AOY08524" "ASU55394" "APQ41782" "ASU55399" "APQ41783"
#> [31] "ANS60026" "ASU55408" "ANC90428" "ASU55418" "ASU55424" "AQX32987"
#> [37] "APB03017" "ASU55410" "ASU55397" "ASU55413" "ASU55420" "ASU55404"
#> [43] "ASU55423" "ANB66182" "ASU55425" "ASU55406" "ASU55398" "ASU55407"
#> [49] "ASU55414" "ASU55405" "ASU55401" "ASU55402" "ASU55421" "ASU55415"
#> [55] "ASU55426" "ASU55412" "ASU55419" "APQ41786" "ASU55390" "AQX32986"
#> [61] "ASU55422" "ARM59239" "ANB66183"
#>