Skip to content

Commit

Permalink
Merge pull request #277 from DendrouLab/deevdevil88-patch-1
Browse files Browse the repository at this point in the history
Update run_scanpyQC_rna.py to fix scrublet merge issue in ingest
  • Loading branch information
deevdevil88 authored May 13, 2024
2 parents f2888d6 + 141a2f5 commit ac0d931
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion panpipes/python_scripts/run_scanpyQC_rna.py
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@
doubletscores = pd.concat(doubletscores, keys=sample_ids.sample_id).reset_index(level="sample_id")
# rename the barcodes to match up qwith what the rna.obs barcodes are
if len(sample_ids) > 1:
doubletscores['barcode'] = doubletscores['barcode'] + '-' + doubletscores['sample_id']
doubletscores['barcode'] = doubletscores['barcode'].astype(str) + '-' + doubletscores['sample_id'].astype(str)
doubletscores = doubletscores.set_index('barcode').drop('sample_id', axis=1)
# merge with rna.obs
rna.obs = rna.obs.merge(doubletscores, how="left", left_index=True, right_index=True)
Expand Down

0 comments on commit ac0d931

Please sign in to comment.