View source: R/Conduct.SH_2N.R
Conduct.SH_2N | R Documentation |
This function returns a list containing p-values of the Conduct.SH_2N STAR test for a set of input topologies (can include networks)
Conduct.SH_2N( list.SpeciesTopologiesNetworks, handle.InputGeneTrees, numeric.NumberOfReps, string.PathDir )
list.SpeciesTopologiesNetworks |
List of class (not multiPhylo) containing the strings defining all plausible topologies to be tested ( can include networks). Topologies are defined in strings (not phylogenetic objects) |
numeric.NumberOfReps |
Number of bootstrap replicates to analyze |
string.PathDir |
String defining the path to a parent directory used for conduct SH_2 STAR test |
handle.GeneTrees |
Phylo object containing a list of the input gene trees |
List Returns a list containing (1) matrix.Change_Delta_BS_Results, (2) vector.Pvalues, and (3) vector.Observed_Delta_ML.
################ # Load depends # ################ library(SpeciesTopoTestR) library(ape) ################################# # Generate example species trees # ################################# string.SpeciesNetwork <- "(((((C:1.0,D:1.0):1)#H1:0::0.5,A:1.0):2,B:1.0):2,#H1:0::0.5);" string.SpeciesNetwork_2 <- "(((((C:1.0,A:1.0):1)#H1:0::0.5,D:1.0):2,B:1.0):2,#H1:0::0.5);" list.SpeciesNetworks <- list() list.SpeciesNetworks[[1]] <- string.SpeciesNetwork list.SpeciesNetworks[[2]] <- string.SpeciesNetwork_2 ########################## # Simulate gene tree set # ########################## handle.Simulated_GeneTreeSet <- Simulate.GeneTrees_From_SpeciesNetwork(string.SpeciesNetwork = string.SpeciesNetwork, string.PathDir = '~/Desktop/', numeric.NumberOfGeneTrees = 10) ##################################### # Conduct SH_2N STAR using networks # ##################################### Conduct.SH_2N(list.SpeciesTopologiesNetworks = list.SpeciesNetworks, handle.InputGeneTrees = handle.Simulated_GeneTreeSet, numeric.NumberOfReps = 100, string.PathDir = '~/Desktop/')
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.