deviance.drc | R Documentation |
Calculate the sum of squared residuals from a non-linear regression fit with the 'drm()' function in the 'drc()' package.
## S3 method for class 'drc'
deviance(object, ...)
object |
a 'drc' object, for which the deviance is required |
... |
Other additional arguments, if necessary |
The value of the deviance extracted from the object object.
Andrea Onofri
X <- c(1, 3, 5, 7, 9, 11, 13, 20)
Y <- c(8.22, 14.0, 17.2, 16.9, 19.2, 19.6, 19.4, 19.6)
# nls fit
model <- nls(Y ~ NLS.asymReg(X, init, m, plateau) )
deviance(model)
# drm fit
model2 <- drm(Y ~ X, fct = DRC.asymReg())
deviance(model2)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.