A wrapper to create a cubic model for curve data.
Usage
create_cubic_model(
curve_data,
conc_var,
signal_var,
dilution_data = lifecycle::deprecated()
)
Value
A linear model object from stats:lm()
with formula
signal_var ~ conc_var + I(conc_var * conc_var * conc_var)
from data diltuion_data
.
Examples
concentration <- c(10, 20, 40, 60, 80, 100)
signal <- c(22561, 31178, 39981, 48390, 52171, 53410)
curve_data <- data.frame(Concentration = concentration,
Signal = signal)
cubic_model <- create_cubic_model(
curve_data,
"Concentration",
"Signal"
)
cubic_model
#>
#> Call:
#> stats::lm(formula = cubic_formula, data = curve_data)
#>
#> Coefficients:
#> (Intercept)
#> 1.502e+04
#> Concentration
#> 8.659e+02
#> I(Concentration * Concentration)
#> -5.910e+00
#> I(Concentration * Concentration * Concentration)
#> 1.096e-02
#>