The function find_poi()
determines the point where the distance
between two lines is minimal, e.g. the distance between a specification or
expiry limit and a confidence or prediction interval, or in other words
the point of intersection (POI). The estimation is done by aid of
uniroot()
from the ‘stats
’ package.
find_poi(
srch_range,
model,
sl,
mode = "minimal",
alpha = 0.05,
ivl = "confidence",
ivl_type = "one.sided",
ivl_side = "lower",
...
)
A numeric value representing the value of \(x\) where the distance between the two lines of interest is minimal is returned.
A vector of length 2
that specifies the endpoints
of the (time) range within which the minimum distance is expected.
A linear model object of type ‘lm
’.
A numeric variable that specifies the “specification limit” (SL). Another kind of acceptance criterion may be regarded as SL.
A character string of either "minimal"
or "all"
,
that specifies if only the minimal distance of a factor regression model
is returned or if the distances of all lines belonging to the different
factor levels is returned. The default is "minimal"
.
A numeric value between 0 and 1 that specifies the significance
level for the calculation of confidence or prediction intervals. The
default is 0.05
.
A character string of either "confidence"
or
"prediction"
that specifies the type of interval of interest.
The default is "confidence"
.
A character string that specifies if a “one sided”
or a “two sided” interval should be calculated, i.e. either
"one.sided"
or "two.sided"
, respectively. The default is
"one.sided"
.
A character string that specifies if the specification
limit, given that the limit has only one side, is an “upper” or a
“lower” bound, i.e. it is specified as either "upper"
or
"lower"
, respectively. The default is "lower"
. If the
specification has two boundaries, then this parameter specifies the
preferred side. If no side is preferred over the other, "both"
can
be used.
Additional named or unnamed arguments passed on to
uniroot()
.
ICH Q1E recommends that “For an attribute known to decrease with
time, the lower one-sided 95 percent confidence limit should be compared
to the acceptance criterion. For an attribute known to increase with time,
the upper one-sided 95 percent confidence limit should be compared to the
acceptance criterion. For an attribute that can either increase or decrease,
or whose direction of change is not known, two-sided 95 percent confidence
limits should be calculated and compared to the upper and lower acceptance
criteria.” Since attributes often either decrease or increase, the default
for ivl_type
is one.sided
.
According to the ARGPM guidance “Stability testing for prescription medicines”, the shelf life or expiry limit is estimated as the point where the upper or lower limit of the 95% confidence interval of the linear model fitted to the data intersects the worst case scenario limit. The worst case scenario limit is obtained by adding/subtracting the absolute difference of specification limit and release limit to/from the common intercept of the test batches or the intercept of the worst performing batch.
The function find_poi()
(find the “point of
intersection”) estimates the value of \(x\) (e.g. the time) where the
difference between the upper or lower confidence or prediction interval and
the upper or lower acceptance criterion (e.g. the specification or the
expiry limit) is minimal, or in other words where the corresponding lines
intersect each other. Confidence or prediction intervals are calculated
for the model
provided. The POI is determined by aid of the
uniroot()
function from the ‘stats
’
package. The distance between the two lines of interest is calculated using
the function get_distance()
, and it is this distance which
uniroot()
tries to minimise. Recommendations on how to estimate shelf
life or expiry can be found in the corresponding section below.
Therapeutic Goods Administration (TGA) of the Department of Health of the Australian Government, Australian Regulatory Guidelines for Prescription Medicines (ARGPM), Stability testing for prescription medicines, Version 1.1, March 2017
International Council for Harmonisation of Technical Requirements for Registration of Pharmaceuticals for Human (ICH), Harmonised Tripartite Guideline, Evaluation of Stability Data Q1E, step 4, February 2003 (CPMP/ICH/420/02).
get_distance
, get_poi_list
,
expirest_osle
, expirest_wisle
,
uniroot
.