metalsinglecell.pp.bbknn#

metalsinglecell.pp.bbknn(adata, batch_key, use_rep='X_pca', neighbors_within_batch=3, random_state=0, copy=False)[source]#

Batch-balanced kNN (sc.external.pp.bbknn); writes obsp + uns['neighbors'].

Parameters:
  • use_rep (str)

  • neighbors_within_batch (int)

  • random_state (int)

  • copy (bool)