pdhoff / amen

R package for analysis of network and dyadic data
27 stars 11 forks source link

use stats::rWishart() in rwish.R for R >= 3.0.2 #1

Open theoldfather opened 8 years ago

theoldfather commented 8 years ago

Using rWishart() provides a small performance gain for newer versions. Conditioning on the R version at the time of function creation rather than inside the function avoids checking the version on each function call.

pdhoff commented 8 years ago

Thanks! It is good to know there is now a built-in Wishart simulator. I will take a look once my classes are over - I want to make sure the conditional definition of rwish.R plays nice with R CMD CHECK.