A wrapper to create a linear model from curve data.
Usage
create_linear_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
from data curve_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)
linear_model <- create_linear_model(
curve_data,
"Concentration",
"Signal"
)
linear_model
#>
#> Call:
#> stats::lm(formula = linear_formula, data = curve_data)
#>
#> Coefficients:
#> (Intercept) Concentration
#> 23708.5 340.1
#>