% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/composite_mle_procedure.R
\name{stat_composite_mle}
\alias{stat_composite_mle}
\title{Composite Hypothesis Procedure for Type-II Censored Samples}
\usage{
stat_composite_mle(
  data,
  n,
  pdf,
  cdf,
  sf = NULL,
  params,
  censoring = c("right", "left"),
  transform = c("malmquist", "ms"),
  optim_control = list()
)
}
\arguments{
\item{data}{Numeric vector of observed order statistics.}

\item{n}{Total sample size (n >= length(data)).}

\item{pdf}{Probability density function taking \code{(x, params)}.}

\item{cdf}{Cumulative distribution function taking \code{(x, params)}.}

\item{sf}{Survival function taking \code{(x, params)}. If \code{NULL}, computed as \code{1 - cdf(x, params)}.}

\item{params}{Named list/vector of starting parameter values for MLE.}

\item{censoring}{Type of censoring: \code{"right"} or \code{"left"}.}

\item{transform}{Transformation method: \code{"ms"} (Michael-Schucany) or \code{"malmquist"}.}

\item{optim_control}{Optional control list passed to \code{\link[stats]{optim}}.}
}
\value{
A list containing:
\item{stat_W2}{Modified Cramér-von Mises statistic (_mW2 or _lW2).}
\item{stat_A2}{Modified Anderson-Darling statistic (_mA2 or _lA2).}
\item{W2}{Raw Cramér-von Mises statistic on standardized residuals.}
\item{A2}{Raw Anderson-Darling statistic on standardized residuals.}
\item{theta_hat}{Estimated parameter values.}
\item{convergence}{Optimization convergence code.}
}
\description{
Evaluates goodness-of-fit under unknown parameters using MLE estimation,
transformation to complete sample, normal residual standardization, and modified CvM/AD statistics.
}
\examples{
data_exp <- c(0.1, 0.2, 0.3, 0.4, 0.7, 1.0, 1.4)
stat_composite_mle(
  data = data_exp, n = 20,
  pdf = function(x, p) dexp(x, rate = p$rate),
  cdf = function(x, p) pexp(x, rate = p$rate),
  params = list(rate = 0.1),
  censoring = "right",
  transform = "malmquist"
)
}
