% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/simulate-breakpoint.R
\name{simulate_breakpoint_data}
\alias{simulate_breakpoint_data}
\title{Simulate data with a breakpoint rho trajectory}
\usage{
simulate_breakpoint_data(
  n_time,
  type = c("single", "double"),
  rho_before = 0.7,
  rho_after = 0.3,
  rho_levels = c(0.7, 0.3, 0.7),
  breakpoint = 0.5,
  breakpoints = c(1/3, 2/3),
  transition_width = 0,
  mu = c(0, 0),
  Phi = matrix(c(0.3, 0.1, 0.1, 0.3), 2, 2),
  sigma_eps = c(1, 1),
  seed = NULL
)
}
\arguments{
\item{n_time}{Number of time points.}

\item{type}{Character; one of \code{"single"} (single breakpoint) or \code{"double"}
(double breakpoint / relapse pattern).}

\item{rho_before}{Rho before breakpoint (default: 0.7).}

\item{rho_after}{Rho after breakpoint (default: 0.3).}

\item{rho_levels}{Numeric vector of three rho levels for double breakpoint
(default: \code{c(0.7, 0.3, 0.7)}). Only used when \code{type = "double"}.}

\item{breakpoint}{Breakpoint location as proportion of \code{n_time - 1} (default: 0.5).}

\item{breakpoints}{Numeric vector of two breakpoints for double type
(default: \code{c(1/3, 2/3)}).}

\item{transition_width}{Number of time points for smooth transition
(default: 0 = abrupt).}

\item{mu}{Intercept vector of length 2 (default: \code{c(0, 0)}).}

\item{Phi}{VAR(1) coefficient matrix, 2x2.}

\item{sigma_eps}{Innovation SDs, length 2 (default: \code{c(1, 1)}).}

\item{seed}{Random seed.}
}
\value{
A named list as returned by \code{\link[=simulate_dcvar]{simulate_dcvar()}}.
}
\description{
Convenience wrapper that combines \code{\link[=rho_step]{rho_step()}} or \code{\link[=rho_double_step]{rho_double_step()}} with
\code{\link[=simulate_dcvar]{simulate_dcvar()}} for quick breakpoint simulation studies.
}
\examples{
sim <- simulate_breakpoint_data(n_time = 100, type = "single", seed = 42)
plot(sim$true_params$rho, type = "l")
}
