TEfitAll | R Documentation |
A wrapper for fitting a TEfit
model to the data
for every unique value of groupingVar. Defaults to
returning a list including two summaries and all models; returning
only a summary is also an option. Most arguments (except, e.g., groupingVar
, a grouping vector)
are identical to, and are passed directly to, TEfit
.
TEfitAll(
varIn,
groupingVar,
groupingVarName = "grouping_var",
returnAll = T,
progressDot = T,
linkFun = list(link = "identity"),
errFun = "ols",
changeFun = "expo",
bootPars = tef_bootList(),
blockTimeVar = NULL,
covarTerms = list(),
control = tef_control()
)
varIn |
Data frame or vector. First column [or vector] must be the time-dependent response variable (left hand side of regression). If available, second column must be the time variable. All other columns are covariates, possibly involved in a link function. |
groupingVar |
Variable (e.g., participant ID) with which to separate TEfit models. Length must be nrows(varIn) |
groupingVarName |
Name of grouping variable |
returnAll |
Logical. Return only a summary (when T), or that summary plus every model, in a list (when F) |
progressDot |
If TRUE, prints a dot after each group fit |
linkFun |
A list defining a link function (i.e., 'identity', 'd_prime', 'weibull', or 'logistic') |
errFun |
A string defining an error function (e.g., 'ols', 'logcosh', 'bernoulli'). |
changeFun |
A string defining the functional form of change (e.g., 'expo', 'power', 'weibull') |
bootPars |
A list defining the details for bootstrapped fits. Defaults to no bootstrapping. Necessary for estimates of uncertainty around fits and for covariance between parameters. |
blockTimeVar |
A string identifying which covariate is the time points of sub-scales (e.g., "blocks" of times within the overall timescale of data collection) |
covarTerms |
An optional list of logical vectors indicating whether parameters should vary by covariates. See examples. |
control |
A list of model parameters. Use of tef_control() is highly recommended. |
TEfit
for fitting a single model;
tef_fitAll2brms
to re-fit the TEfitAll output using brms-package
## Not run:
m <- TEfitAll(anstrain[,c('acc','trialNum')],groupingVar = anstrain$subID,groupingVarName = 'subID',bootPars = tef_bootList(resamples = 20))
summary(m)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.