aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--NAMESPACE4
-rw-r--r--R/WP.R2
-rw-r--r--R/WP_unknown.R2
3 files changed, 8 insertions, 0 deletions
diff --git a/NAMESPACE b/NAMESPACE
index eb1e732..461d6f8 100644
--- a/NAMESPACE
+++ b/NAMESPACE
@@ -4,3 +4,7 @@ export(ID)
export(IDEA)
export(WP)
export(seqB)
+importFrom(stats,pexp)
+importFrom(stats,pgamma)
+importFrom(stats,qexp)
+importFrom(stats,qgamma)
diff --git a/R/WP.R b/R/WP.R
index 76012be..c8178b7 100644
--- a/R/WP.R
+++ b/R/WP.R
@@ -73,6 +73,8 @@
#' res4 <- WP(NT=NT[1:5], mu=5/7) # serial distribution has mean of five days
#' res4$Rhat
#'
+#' @importFrom stats pexp qexp
+#'
#' @export
WP <- function(NT, mu=NA, search=list(B=100, shape.max=10, scale.max=10), tol=0.999) {
if (is.na(mu)) {
diff --git a/R/WP_unknown.R b/R/WP_unknown.R
index 832a3ba..f339836 100644
--- a/R/WP_unknown.R
+++ b/R/WP_unknown.R
@@ -20,6 +20,8 @@
#' \code{J0} (the location for the maximum likelihood estimator \code{Rhat}). If \code{JJ} and \code{J0}
#' are not the same, this means that the maximum likelihood estimator is not unique.
#'
+#' @importFrom stats pgamma qgamma
+#'
#' @keywords internal
WP_unknown <- function(NT, B=100, shape.max=10, scale.max=10, tol=0.999) {
shape <- seq(0, shape.max, length.out=B+1)