The functions seeks to determine the reaction order and kinetic rate constant for chemical models that best fit degradation kinetic data. The input of the function is a data-frame organized as follows:
first columns, time data;
second columns, concentration data;
third column (optional, but highly recommended), experimental error
Arguments
- dframe
a data-frame with 2 or 3 columns, containing time, concentrations, and (optional) error data.
Value
A ord_res
object containing in a list the following information:
the phase space coordinates of transformed data;
the linear regression performed in the phase space;
a boolean variable indicating if the estimate of the degradation rate constant is statistically significant;
non-linear regression performed using a n^th^-order kinetic model (if n=0 the regression is linear);
the data-frame given as the input;
the estimated reaction order.
See also
results()
to print the results or goodness_of_fit()
to visualize
the major goodness-of-fit measures; plot_ord()
to plot the regressions in
both the phase and conventional spaces;
kin_regr()
to extract the best kinetic model that explain the data and
phase_space()
to extract the linear regression in the phase space.
Examples
t <- c(0, 4, 8, 12, 16, 20)
conc <- c(1, 0.51, 0.24, 0.12, 0.07, 0.02)
err <- c(0.02, 0.05, 0.04, 0.04, 0.03, 0.02)
dframe <- data.frame(t, conc)
res <- det_order(dframe)
#> Reaction order estimated: 1
class(res)
#> [1] "ord_res"
dframe2 <- data.frame(t, conc, err)
res2 <- det_order(dframe2)
#> Reaction order estimated: 1
res2[[5]] == dframe2
#> t conc err
#> [1,] TRUE TRUE TRUE
#> [2,] TRUE TRUE TRUE
#> [3,] TRUE TRUE TRUE
#> [4,] TRUE TRUE TRUE
#> [5,] TRUE TRUE TRUE
#> [6,] TRUE TRUE TRUE