Construct the time period adjustment in the design matrix
construct_timeadjust(
Cl,
timepoints,
timeAdjust = "factor",
period = NULL,
timeBlk = NULL
)
integer (vector), number of clusters per sequence group (in SWD), or number in control and intervention (in parallel designs)
numeric (scalar or vector), number of timepoints (periods). If design is swd, timepoints defaults to length(Cl)+1. Defaults to 1 for parallel designs.
character, specifies adjustment for time periods. One of the following: "factor", "linear", "none", "periodic". Defaults to "factor".
numeric (scalar)
an optional user defined matrix that defines the time adjustment in one cluster. Is repeated for every cluster.
a matrix with one row for every cluster at every timepoint and columns depending of adjustment type.