This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Use HarmonyMatrix to normalize the batch effect

When I use "HarmonyMatrix" function to normalize the gene expression matrix (not PCA matrix), I successfully run the example data using the command line below, in which includes 2000 genes and 200 cells.

library(harmony)
harmonized_pcs <- HarmonyMatrix(
  data_mat  = gene_exp_mat,       # Matrix with coordinates for each cell (row) along many PCs (columns)
  meta_data = meta_data, # Dataframe with information for each cell (row)
  vars_use  = "dataset", # Column in meta_data that defines dataset for each cell
)

But, when I apply this function to my own data, which includes 30000 genes and 10000 cells. It reported the following error. Is it related to the memory issue? Does anyone meet this kind of issue previously? thank you so much.

Error in (function (A, nv = 5, nu = nv, maxit = 1000, work = nv + 7, reorth = TRUE,  : 
  BLAS/LAPACK routine 'DLASCLDLALS0DLALSADL' gave error code -4
harmony scrna-seq

0 answers

No answers yet.

Log in to answer this question.