liamrevell / phytools

GNU General Public License v3.0
207 stars 56 forks source link

improve ancThresh, include C++ version of threshState #20

Closed KlausVigo closed 6 years ago

KlausVigo commented 6 years ago

Hi @liamrevell , here are the main changes to use the C function of theshState. It also simplifies some code as sapply is now not necessary in many cases. logPrior is just a bit more elegant and also a bit faster.

liamrevell commented 6 years ago

Hi Klaus. I merged this but then reverted back because it breaks ancThresh with the error: Error in if (p.odds > runif(n = 1)) { : missing value where TRUE/FALSE needed For the most recent example from my blog. Not sure what's going on. - Liam