When fitting probit BKMR, one can occasionally get the following error:
“Error in checkSymmetricPositiveDefinite(H, name = “H”) :
H must be positive definite”
A solution that often works is to set the argument ‘est.h = TRUE’ in the kmbayes function. Doing this leads to a different sampler being used for one of the steps of the MCMC algorithm, which can get around this error.
在kmbayes函数里加上 'est.h = TRUE’参数就行了