aboutsummaryrefslogtreecommitdiff
path: root/R/summary.nlme.mmkin.R
diff options
context:
space:
mode:
authorJohannes Ranke <jranke@uni-bremen.de>2020-11-09 11:50:02 +0100
committerJohannes Ranke <jranke@uni-bremen.de>2020-11-09 11:50:02 +0100
commit8ba0bc6f52183ad97377e4d13d082be13b0383bd (patch)
tree72ca01d9332d0b94f35bbf985915b36be97f26bf /R/summary.nlme.mmkin.R
parent17258b37e7f22008298d350a2dc954d71d2fd496 (diff)
Fix std in summary.nlme.mmkin(..., data = TRUE)
Diffstat (limited to 'R/summary.nlme.mmkin.R')
-rw-r--r--R/summary.nlme.mmkin.R6
1 files changed, 5 insertions, 1 deletions
diff --git a/R/summary.nlme.mmkin.R b/R/summary.nlme.mmkin.R
index 7e404e00..d930f845 100644
--- a/R/summary.nlme.mmkin.R
+++ b/R/summary.nlme.mmkin.R
@@ -131,7 +131,11 @@ summary.nlme.mmkin <- function(object, data = FALSE, verbose = FALSE, distimes =
object$data[["value"]] <- NULL
object$data[["predicted"]] <- predict(object)
object$data[["residual"]] <- residuals(object, type = "response")
- object$data[["std"]] <- object$sigma <- 1/attr(object$modelStruct$varStruct, "weights")
+ if (is.null(object$modelStruct$varStruct)) {
+ object$data[["std"]] <- object$sigma
+ } else {
+ object$data[["std"]] <- 1/attr(object$modelStruct$varStruct, "weights")
+ }
object$data[["standardized"]] <- residuals(object, type = "pearson")
object$verbose <- verbose

Contact - Imprint