Description Usage Arguments Details Value Author(s) Examples
takes data read into R using read.starbeast and uses posterior predictive simulation to evaluate the fit of the sequence data to the estimated gene trees from the analysis
1 | analyze.sequences(data, seqgendir = "/directory/containing/seqgen")
|
data |
data read in using read.starbeast |
seqgendir |
seqgendir is the directory containing the a compiled executable of Rambaut's seq-gen software. this software is used to simulate DNA sequence data. |
This function analyzes the fit of DNA sequence data to the estimated gene trees generated by *BEAST. It does this by simulating new sequence data from the posterior and comparing the simulated and empirical sequence data. It uses four test statistics: the number of variable sites, the phylogenetic likelihood of the data given the gene tree, the multinomial likelihood of the sequence data and the GC statistic (the difference between the multinomial and phylogenetic likelihoods). It calculates these statistics for each locus (or each subset of nucleotides if a locus is partitioned). The results can be summarized using 'summary' or visualized using 'plot'.
The function returns an object of class "sequenceteststats". This object contains three lists, "empirical" and "simulated" and "test.stats", which contain the empirical ("empirical") and simulated ("simulated") values and the difference between them ("test.stat"), respectively. "empirical" contains 3 matrices and one vector containing the test statistics for the empirical data. "simulated" contains 4 matrices with those test statistics. "test.stat" contains 4 matrices with the differences between simulated and empirical. Those differences give a test distribution whose expectation is 0. The four elements of each list are called "phy.likelihood", "multi.likelihood", "gcstat" and "v.sites"
Noah Reid
1 2 3 | ##---- Should be DIRECTLY executable !! ----
##-- ==> Define data, use random,
##-- or do help(data=index) for the standard data sets.
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.