Creates matrix of binary cross-fitting fold indicators (N x # cross-folds)
prep_cf_mat(n, cf, w_mat = NULL, cl = NULL)
Logical matrix of cross-fitting folds (N x # folds).
Number of observations.
Number of cross-fitting folds.
Optional logical matrix of treatment indicators (N x T+1). If specified, cross-fitting folds will preserve the treatment ratios from full sample.
Optional vector of cluster variable if cross-fitting should account for clusters.