richelbilderbeek / R

My notes on the R programming language
GNU General Public License v3.0
7 stars 3 forks source link

geiger does not check correct parameter use #8

Closed richelbilderbeek closed 8 years ago

richelbilderbeek commented 8 years ago
library(geiger)

# Should give error: 'if stopping criterium is set to 'time', please do not set the number of taxa 'n'
sim.bdtree(b = 0.4, d = 0.1, stop = "time", n = 10, t = 10)
# Should give error: 'if stopping criterium is set to 'taxa', please do not set the time of the simulation 't'
sim.bdtree(b = 0.4, d = 0.1, stop = "taxa", n = 10, t = 10)
# Should give error: 'if stopping criterium is set to 'time', please provide a value for 'n''
sim.bdtree(b = 0.4, d = 0.1, stop = "time", n = 10)
# Should give error: 'if stopping criterium is set to 'taxa', please provide a value for 'n''
sim.bdtree(b = 0.4, d = 0.1, stop = "taxa", t = 10)
richelbilderbeek commented 8 years ago

Posted the message here: https://github.com/mwpennell/geiger-v2/issues/19