anova.modeler {flexFitR} | R Documentation |
Extra Sum-of-Squares F-Test for modeler
objects
Description
Perform an extra sum-of-squares F-test to compare two nested
models of class modeler
. This test assesses whether the additional
parameters in the full model significantly improve the fit compared to the
reduced model.
Usage
## S3 method for class 'modeler'
anova(object, full_model = NULL, ...)
Arguments
object |
An object of class |
full_model |
An optional object of class |
... |
Additional parameters for future functionality. |
Value
A tibble
containing columns with the F-statistic and
corresponding p-values, indicating whether the full model provides a
significantly better fit than the reduced model.
Author(s)
Johan Aparicio [aut]
Examples
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))
plot(mo_1)
mo_2 <- modeler(dt, X, Y, fn = "fn_quad", param = c(a = 1, b = 10, c = 5))
plot(mo_2)
anova(mo_1, mo_2)
[Package flexFitR version 1.2.0 Index]