fit_drms {CBASSED50} | R Documentation |
Fit Dynamic Regression Models (DRMs)
Description
This function fits dynamic regression models (DRMs) to a given dataset using the specified grouping properties and DRM formula.
Usage
fit_drms(
dataset,
grouping_properties,
drm_formula,
is_curveid = FALSE,
LL.4 = FALSE
)
Arguments
dataset |
A data frame containing the dataset on which to fit the DRMs. |
grouping_properties |
A character vector specifying the names of columns in the dataset that will be used as grouping properties for fitting separate DRMs. |
drm_formula |
A formula specifying the dynamic regression model to be fitted. This formula should follow the standard R formula syntax (e.g., y ~ x1 + x2). |
is_curveid |
A boolean value indicating if you want to use this parameter to fit the model |
LL.4 |
Logical. If TRUE, the LL.4 model is used instead of LL.3. LL.3 is preferred, as PAM data is expected to never be lower than zero. In cases with overly correlated data and steep slopes, LL.4 allows the lower limit to vary, which can help to better fit the model. |
Value
A list of fitted DRM models, with each element corresponding to a unique combination of grouping property values.
Examples
data(cbass_dataset)
preprocessed_data <- preprocess_dataset(cbass_dataset)
fit_drms(preprocessed_data,
c("Site", "Condition", "Species", "Genotype"),
"Pam_value ~ Temperature")