goodness_of_fit | R Documentation |
modeler
Generic function calculating Akaike's ‘An Information Criterion’
for fitted model object of class modeler
.
## S3 method for class 'modeler'
AIC(object, ..., k = 2)
## S3 method for class 'modeler'
BIC(object, ...)
object |
An object inheriting from class |
... |
Further parameters. For future improvements. |
k |
Numeric, the penalty per parameter to be used; the default k = 2 is the classical AIC. |
A tibble
with columns giving the corresponding AIC and BIC.
Johan Aparicio [aut]
library(flexFitR)
dt <- data.frame(X = 1:6, Y = c(12, 16, 44, 50, 95, 100))
mo_1 <- modeler(dt, X, Y, fn = "fn_lin", param = c(m = 10, b = -5))
mo_2 <- modeler(dt, X, Y, fn = "fn_quad", param = c(a = 1, b = 10, c = 5))
AIC(mo_1)
AIC(mo_2)
BIC(mo_1)
BIC(mo_2)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.