This function runs the gRNA precomputation on a selected "pod" of gRNAs (as identified by the pod_id). It stores the result in the gRNA precomputation directory.

run_gRNA_precomputation_at_scale(
  pod_id,
  gRNA_precomp_dir,
  combined_perturbation_matrix,
  covariate_matrix,
  log_dir,
  B,
  seed
)

Arguments

pod_id

ID of the pod for which to do the precomputation

gRNA_precomp_dir

file path to the gRNA precomputation directory

combined_perturbation_matrix

a binary matrix of perturbations (i.e., gRNA group-to-cell assignments); the rows (i.e., gRNA groups) and columns (i.e., cell barcodes) should be named.

covariate_matrix

the cell-specific matrix of technical factors, ideally containing the following covariates: log-transformed gene library size (numeric), log-transformed gRNA library size (numeric), percent mitochondrial reads (numeric), and batch (factor). The rows (i.e., cell barcodes) should be named

log_dir

file path to the log directory

B

number of resamples to draw for the conditional randomization test

seed

seed to the random number generator