A helper function to add predictors to a filebacked matrix of data
add_predictors(obj, add_predictor, id_var, rds_dir, outfile, quiet)A list of 2 components:
design_matrix - a bigSNP object with an added element representing the matrix that includes the additional predictors as the first few columns
unpen - an integer vector that ranges from 1 to the number of added predictors. Example: if 2 predictors are added, unpen = 1:2
A bigSNP object
Optional: add additional covariates/predictors/features from an external file (i.e., not a PLINK file).
String specifying which column of the PLINK .fam file has the unique sample identifiers.
The path to the directory in which you want to create the new .rds and .bk files. Defaults to data_dir(from process_plink() call)
A string with the name of the filepath for the log file
Logical: should console messages be silenced? Defaults to FALSE