% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/qgarch_fit.R
\name{qgarch_fit}
\alias{qgarch_fit}
\title{Fit generalized qgarch(m, n) models}
\usage{
qgarch_fit(
  x,
  model = c("zero", "restricted", "free", "threshold"),
  arch_order = 1L,
  garch_order = 1L,
  threshold_indicator = NULL,
  start = NULL,
  rho = 1,
  steptol = 1e-10,
  typsize = 0.1,
  iterlim = 300L,
  print.level = 0,
  hessian = TRUE,
  vcov_type = c("auto", "sandwich", "hessian", "opg", "none")
)
}
\arguments{
\item{x}{A numeric vector or one-column data frame containing the observed
series. The series must contain only finite, non-missing values.}

\item{model}{Character string specifying the model variant. Must be one of
\code{"zero"}, \code{"restricted"}, \code{"free"}, or \code{"threshold"}.}

\item{arch_order}{Positive integer giving the ARCH lag order \code{m}.}

\item{garch_order}{Positive integer giving the GARCH lag order \code{n}.}

\item{threshold_indicator}{Optional threshold indicator used only when
\code{model = "threshold"}. Must have the same length as \code{x}. Nonzero values
are converted to 1 and zero values to 0.}

\item{start}{Optional starting values. May be \code{NULL}, a numeric vector, or a
list of numeric vectors.}

\item{rho}{Scalar used in the restricted-lambda mapping.}

\item{steptol}{Step tolerance passed to \code{\link[stats:nlm]{stats::nlm()}}.}

\item{typsize}{Typical size passed to \code{\link[stats:nlm]{stats::nlm()}}. A single value is
repeated to the appropriate length.}

\item{iterlim}{Maximum number of iterations passed to \code{\link[stats:nlm]{stats::nlm()}}.}

\item{print.level}{Print level passed to \code{\link[stats:nlm]{stats::nlm()}}.}

\item{hessian}{Logical; should the Hessian be returned by \code{\link[stats:nlm]{stats::nlm()}}?}

\item{vcov_type}{Character string controlling standard-error estimation.
One of \code{"auto"}, \code{"sandwich"}, \code{"hessian"}, \code{"opg"}, or \code{"none"}.
In \code{"auto"} mode, Hessian-based standard errors are tried first.}
}
\value{
An object of class \code{"qgarch"}.
}
\description{
Fits QGARCH-in-mean models using nonlinear minimization of the negative
log-likelihood. Four variants are supported: a zero-lambda model, a
restricted-lambda model, a free-lambda model, and a threshold model with
state-dependent lambda.
}
