% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/convenience.R
\name{cpy}
\alias{cpy}
\title{Generalized Process Capability Index (Cpy)}
\usage{
cpy(dist, LSL, USL, LDL = NULL, UDL = NULL, p0 = NULL)
}
\arguments{
\item{dist}{A \code{\link{pci_dist}} object.}

\item{LSL}{Lower specification limit.}

\item{USL}{Upper specification limit.}

\item{LDL}{Lower desirable limit (optional if \code{p0} is given).}

\item{UDL}{Upper desirable limit (optional if \code{p0} is given).}

\item{p0}{Desired yield (optional if \code{LDL}/\code{UDL} are given).}
}
\value{
Numeric value of \eqn{C_{py}}.
}
\description{
\eqn{C_{py} = p / p_0 = \bigl(F(USL)-F(LSL)\bigr) /
  \bigl(F(UDL)-F(LDL)\bigr)}, where \eqn{F} is the CDF from \code{dist}
(Maiti, Saha & Nanda, 2010).
}
\examples{
d <- pci_dist_normal(mean = 60, sd = 1)
cpy(d, LSL = 57, USL = 63, LDL = 57, UDL = 63)   # 1.0
}
\seealso{
\code{\link{pci}}, \code{\link{pci_dist}}
}
