diff --git a/DESCRIPTION b/DESCRIPTION index 86e169dc..8c141dd9 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,6 +1,6 @@ Package: blavaan Title: Bayesian Latent Variable Analysis -Version: 0.5-6.1306 +Version: 0.5-6.1307 Authors@R: c(person(given = "Edgar", family = "Merkle", role = c("aut", "cre"), email = "merklee@missouri.edu", diff --git a/R/blavaan.R b/R/blavaan.R index 7bae4a5c..a217b698 100644 --- a/R/blavaan.R +++ b/R/blavaan.R @@ -697,7 +697,7 @@ blavaan <- function(..., # default lavaan arguments fnm <- paste0(jagdir, "/sem.", fext) if(target %in% c("stan", "cmdstan")){ if(mcmcextra$dosam){ - cat(bsam::stanmodels$stanmarg_bsam@model_code, file = fnm) + cat(getFromNamespace("stanmodels", "bsam")$stanmarg_bsam@model_code, file = fnm) } else { cat(stanmodels$stanmarg@model_code, file = fnm) } @@ -726,7 +726,7 @@ blavaan <- function(..., # default lavaan arguments } else if(target == "cmdstan"){ rjarg <- with(jagtrans, list(data = data, init = inits)) } else if(mcmcextra$dosam){ - rjarg <- with(jagtrans, list(object = bsam::stanmodels$stanmarg_bsam, + rjarg <- with(jagtrans, list(object = getFromNamespace("stanmodels", "bsam")$stanmarg_bsam, data = data, pars = sampparms, init = inits))