View source: R/linear_nonlinear_fits.R
linear_nonlinear_fits | R Documentation |
This function fits a GAM glm in a linear and non-linear framework and tests if the glm GAM with a smooth independent is a better fit to the data.
linear_nonlinear_fits( wdata, dependent, independent, covariables = NA, rnt_dependent = TRUE, bam = FALSE, nthread_count = 1 )
wdata |
a data frame of data with appropriate column names |
dependent |
a string that matches a column name in wdata that you would like to define as the dependent or response variable in your analysis |
independent |
a string that matches a column name in wdata that you would like to define as the independent or primary explanatory variable of interest in your analysis |
covariables |
a string or character vector that matches column names in wdata that you would like to define as additional covariate in your model. Set as NA, if you have no covariates and thus would like to run a univariate analysis. |
rnt_dependent |
TRUE or FALSE, would you like to rank normal transform your dependent variable prior to fitting the data? Default value is TRUE. Uses the rntransform() function in this package to rank normal transform. |
bam |
if you would like to run the GAM with bam(), for very large data sets, then set bam = TRUE. Default is bam = FALSE and gam() is used. |
nthread_count |
number of compute threads to use in your bam(). |
linear_nonlinear_fits()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.