% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/simulate_treatment.R
\name{simulate_treatment}
\alias{simulate_treatment}
\title{Simulate Treatment}
\usage{
simulate_treatment(config, wide = FALSE, debug = TRUE, lean = FALSE)
}
\arguments{
\item{config}{A configuration object containing treatment scheme and process information.}

\item{wide}{Logical indicating whether to return results in wide format.}

\item{debug}{Logical indicating whether to print debug information.}

\item{lean}{Logical indicating whether to return only essential results for web applications.}
}
\value{
If \code{lean} is TRUE, returns a list containing only the long-format treatment events.
If \code{wide} is TRUE, returns a list containing long-format events, wide-format events,
wide-format scheme events, treatment schemes, and treatment parameters.
If \code{wide} is FALSE, returns a list containing long-format events, treatment schemes,
and treatment parameters.
}
\description{
This function simulates treatment data for pathogen processes based on the provided configuration.
It generates treatment events and parameters, and can return results in either long or wide format.
}
\details{
This function does the same thing as kwb.qmra::simulate_treatment(),
but it is bundled with \emph{ambre} to avoid a hard dependency on the
unmaintained package.
}
\examples{
# Example usage of simulate_treatment
\donttest{
scenario_test <- create_scenario(
  system.file("input_1culture_2pop.xlsx", package = "ambre")
)
scenario_updated <- update_pathogen(scenario = scenario_test,
 pathoName = c("Campylobacter jejuni","Rotavirus"))
config <- scenario_updated$config[[1]]

# Simulate treatment data
result <- simulate_treatment(config, wide = TRUE, debug = FALSE, lean = FALSE)

}
}
\references{
Sonnenberg H (2024). kwb.utils: General Utility Functions Developed at KWB. R package version 0.15.0
URL: \url{https://github.com/kwb-r/kwb.utils}
(MIT Licence)
}
