- fitlist
A list of models fitted with lme4, base R (lm or glm), or glmmrBase. All models should be fit using the
same data frame.
- tr_var
String indicating the name of the column in data that is a binary indicator
for whether the observation was under the treatment (1=treatment, 0=control)
- cl_var
String specifying the name of the column identifying the clusters/cluster-time
- data
A data frame containing the data used to fit the models in fitlist
- alpha
Numeric. 100(1-alpha)% confidence intervals are calculated. Default it 0.05
- plots
Logical indicating whether to plot permutational distributions and confidence
interval search during running of function. Default is TRUE
- n_permute
Number of permutations of the randomisation test to run
- nsteps
Number of steps of the confidence interval search process
- type
Method of correction: options are "rw" = Romano-Wolf randomisation test based stepdown, "h"
= Holm standard stepdown, "h" = Holm stepdown using randomisation test, "b" = standard Bonferroni, "br" =
Bonerroni using randomisation test, or "none" = randomisation test with no correction.
- rand_func
String of the name of a function that re-randomises the clusters. The function
must take the arguments nJ for the number of clusters and nT for the number of time periods.
The function should produce a data frame that identifies the clusters in the treatment group under the new
randomisation scheme. The data frame can either have a single column with name cl_var or
two columns of cl_var and t identifying the cluster ID and time period a cluster joins
the treatment group. If NULL then clusters are randomised in a 1:1 ratio to treatment and control
- confint
Logical indicating whether to run the confidence interval search process
- sigma
optional, list of estimated covariance matrices of the observations from the models in fitlist.
If provided then the weighted q-score statistic is used.
- ci_start_values
Optional list. The list should contain named vectors "upper" and/or "lower" that provide
a set of starting values for the upper and/or lower confidence interval searches, respectively. Alternatively,
a named scalar scale can be provided such that the starting values of the confidence interval search procedure
are est +/- scale*SE.
- verbose
Logical indicating whether to provide detailed output