diff --git a/inst/tinytest/test_ancestral.R b/inst/tinytest/test_ancestral.R index bd01eb41..14fa79d3 100644 --- a/inst/tinytest/test_ancestral.R +++ b/inst/tinytest/test_ancestral.R @@ -29,7 +29,8 @@ test_acctran <- ancestral.pars(tree, dna, "ACCTRAN") data(Laurasiatherian) -fit <- pml_bb(Laurasiatherian[,1:100], "JC", rearrangement = "none") +fit <- pml_bb(Laurasiatherian[,1:100], "JC", rearrangement = "none", + control=pml.control(trace=0)) anc_ml <- ancestral.pml(fit) write.ancestral(anc_ml) align <- read.phyDat("ancestral_align.fasta") @@ -37,7 +38,7 @@ tree <- read.tree("ancestral_tree.nwk") df <- read.table("ancestral.state", header=TRUE) anc_ml_disc <- ancestral(tree, align, df) expect_equal(anc_ml[[1]], anc_ml_disc[[1]]) -expect_equal(anc_ml[[2]], anc_ml_disc[[2]]) +expect_equal(anc_ml[[2]][tree$tip.label], anc_ml_disc[[2]]) expect_equal(anc_ml[[3]], anc_ml_disc[[3]]) expect_equal(anc_ml[[4]], anc_ml_disc[[4]]) unlink(c("ancestral_align.fasta", "ancestral_tree.nwk", "ancestral.state"))