% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/bivariate_laplace_residual.R
\name{nbuhr_test}
\alias{nbuhr_test}
\title{Test NBUHR / NWUHR Aging Class}
\usage{
nbuhr_test(
  t2 = 1,
  t1_grid = seq(0.1, 5, by = 0.1),
  surv_fn = NULL,
  k1 = 1,
  k2 = 1,
  theta = 0
)
}
\arguments{
\item{t2}{Fixed value of the second age coordinate.}

\item{t1_grid}{Numeric vector of \eqn{t_1} values to check (default 0.1 to
5 in steps of 0.1).}

\item{surv_fn}{Joint survival function; defaults to Gumbel bivariate
exponential.}

\item{k1, k2, theta}{Gumbel parameters.}
}
\value{
A list with components:
  \describe{
    \item{\code{class1}}{Character: \code{"NBUHR"}, \code{"NWUHR"}, or
      \code{"neither"} for the first component.}
    \item{\code{class2}}{Same for the second component.}
    \item{\code{h1_grid}}{Numeric vector of \eqn{h_1(t_1,t_2)} values.}
    \item{\code{h2_grid}}{Numeric vector of \eqn{h_2(t_1,t_2)} values.}
  }
}
\description{
Checks whether a bivariate lifetime distribution belongs to the NBUHR
(New Better than Used in Hazard Rate) or NWUHR (New Worse than Used) aging
class.  A distribution is NBUHR if
\deqn{h_1(0,t_2) \ge h_1(t_1,t_2)\;\text{ for all }t_1 > 0}
and similarly for the second component.  The function evaluates this at a
grid of \eqn{t_1} values.
}
\examples{
nbuhr_test(t2 = 1, k1 = 1, k2 = 1, theta = 0.3)
nbuhr_test(t2 = 0.5,
           surv_fn = function(x1, x2) exp(-(x1 + x2)))

}
\references{
Jayalekshmi S., Rajesh G., Nair N.U. (2022), Definition 3.2.
\doi{10.1080/03610926.2022.2085874}
}
