aboutsummaryrefslogtreecommitdiff
path: root/R/summary.mkinfit.R
diff options
context:
space:
mode:
authorJohannes Ranke <jranke@uni-bremen.de>2020-05-29 15:03:04 +0200
committerJohannes Ranke <jranke@uni-bremen.de>2020-05-29 15:03:04 +0200
commit510436646b1bdd5b8cfab70be29334bd3cc9c828 (patch)
tree4b3e26f658e822e18d09e2d939a5c89214566b6d /R/summary.mkinfit.R
parent609bfe2fd7ecbdcad5f5d641f0db51541dcd6a4e (diff)
Warn if standardized residuals are unlikely normal
This revealed a bug in the data returned in mkinfit$data in the case of the d_3 algorithm, which also affected the residual plot - the data from the direct fitting was not returned even if this was the better method.
Diffstat (limited to 'R/summary.mkinfit.R')
-rw-r--r--R/summary.mkinfit.R5
1 files changed, 5 insertions, 0 deletions
diff --git a/R/summary.mkinfit.R b/R/summary.mkinfit.R
index 2dc74bd7..2c291ffd 100644
--- a/R/summary.mkinfit.R
+++ b/R/summary.mkinfit.R
@@ -165,6 +165,7 @@ summary.mkinfit <- function(object, data = TRUE, distimes = TRUE, alpha = 0.05,
}
ans$bparms.ode <- object$bparms.ode
+ ans$shapiro.p <- object$shapiro.p
ep <- endpoints(object)
if (length(ep$ff) != 0)
ans$ff <- ep$ff
@@ -228,6 +229,10 @@ print.summary.mkinfit <- function(x, digits = max(3, getOption("digits") - 3), .
row.names = " "))
}
+ if (!is.null(x$shapiro.p) && x$shapiro.p < 0.05) {
+ warning("The p-value for the Shapiro-Wilk test of normality on standardized residuals is < 0.05")
+ }
+
cat("\nOptimised, transformed parameters with symmetric confidence intervals:\n")
print(signif(x$par, digits = digits))

Contact - Imprint