% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/build_ebmed_model_mcont_ycat.R
\name{build_ebmed_model_mcont_ycat}
\alias{build_ebmed_model_mcont_ycat}
\title{Build JAGS Model String (Continuous M & Binary Y)}
\usage{
build_ebmed_model_mcont_ycat(P, K, parms)
}
\arguments{
\item{P}{Integer. The number of predictors/covariates.}

\item{K}{Integer. The number of mediators.}

\item{parms}{A \code{data.frame} generated by \code{\link{make_parms_main}}
containing columns: \code{priors}, \code{distribution}, \code{arguments},
and \code{template}.}
}
\value{
A character string containing the full JAGS model specification.
}
\description{
This internal function generates a JAGS model string that uses Gaussian
likelihoods for the mediators and a logistic regression (logit link)
for the binary outcome. It incorporates spike-and-slab variable selection
on all mediation pathways.
}
\details{
Constructs the JAGS model specification for a Bayesian mediation model
where mediators are continuous and the outcome is binary (0/1).


The model uses a mixed-likelihood approach:
\itemize{
  \item \strong{Mediator Models:} \eqn{M_k \sim Normal(\mu_{M_k}, \tau_{M_k})}.
  Variable selection is applied to the \eqn{a}-paths from \eqn{X}.
  \item \strong{Outcome Model:} \eqn{Y \sim Bernoulli(p_y)}, where
  \eqn{logit(p_y)} is a linear combination of predictors and mediators.
  \item \strong{Precision:} Note that \code{y.prec} is not used in this
  formulation as the outcome is binary.
}
}
\seealso{
\code{\link{buzzEBMcontMcatY}}, \code{\link{define_init_values}}
}
\keyword{internal}
