Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement sample demultiplexing followed by VDJ + feature barcode analysis per sample #343

Open
herpov opened this issue Jun 28, 2024 · 5 comments
Labels
enhancement New feature or request

Comments

@herpov
Copy link

herpov commented Jun 28, 2024

Description of feature

I am currently looking into using scrnaseq for a clinical trial. In our setup we have GEX, FB, and VDJ data for several patients which are hashed using Totalseq-C. Currently, cellranger does not support sample demultiplexing combined with immune profiling (10x Q&A).

The solution proposed by 10x is to first run cellranger in order to demultiplex by sample (omitting TCRseq and FB) followed by conversion of .bam to .fastq for each sample output, and then finally run cellranger for each sample (now including TCRseq and FB).

I think it is a fairly common setup with multiplexed immune profiling data and I therefore suggest that this is implemented in nf-core/scrnaseq.

The implementation would require a check of the --input samplesheet.csv or a separate argument to detect when demultiplexing is combined with immune profiling. A check of the --input samplesheet.csv might simply be detecting if both cmo and vdj are listed as a feature_type (see example samplesheet.csv). In this example the cell hasing barcodes are sequenced together with the feature barcodes.

The steps to execute cellranger multi for sample demultiplexing and later for immune profiling per sample are described in detail here.

The final outcome should be VDJ and FB annotations of each sample individually.

Tasks

No tasks being tracked yet.
@herpov herpov added the enhancement New feature or request label Jun 28, 2024
@fmalmeida
Copy link
Contributor

Hi @herpov ,
The current version of the pipeline has cellrangermulti included in it.
We added a documentation for it in this section of the docs: https://github.com/nf-core/scrnaseq/blob/master/docs/usage.md#if-using-cellranger-multi

I think what you have proposed, might be comprehended by it right now. Do you think the same, @grst ?

So, @herpov, could you check it out and give it a try to see if it indeed does allow you to perform your analysis? If not, we can further discuss what is missing there to be implemented.

@NNazeu
Copy link

NNazeu commented Jul 4, 2024

Hi @fmalmeida,
The data used can be found in https://www.10xgenomics.com/analysis-guides/demultiplexing-and-analyzing-5%E2%80%99-immune-profiling-libraries-pooled-with-hashtags

When following the guide provided by 10x we perform three steps

  1. Demultiplex: Assign cells to samples (FB and GEX data)
  2. Convert per sample BAM files to FASTQs for the GEX data
  3. Run cellranger multi for GEX, FB, and VDJ data

In order to run the nextflow pipeline we've used the following metadata:

Command line:
nextflow run nf-core/scrnaseq "-c aws_bco.config -profile docker —aligner cellrangermulti --fasta https://ftp.ensembl.org/pub/release-110/fasta/homo_sapiens/dna/Homo_sapiens.GRCh38.dna.primary_assembly.fa.gz--gtf https://ftp.ensembl.org/pub/release-110/gtf/homo_sapiens/Homo_sapiens.GRCh38.110.gtf.gz --input samplesheet.csv --cellranger_multi_barcodes barcodes_samplesheet.csv --fb_reference fb_reference.csv --gex_cmo_set cmo_set.csv --outdir crmulti/output -resume -bg

Log message:
[libraries] The combination of VDJ libraries and Multiplexing Capture libraries is not supported.

This log message makes us think that the pipeline does not support demultiplexing and immune profiling per sample at the same time.

@grst
Copy link
Member

grst commented Jul 4, 2024

Hi @NNazeu,

in principle I'd be open to adding this feature, but I won't be a priority for myself or @fmalmeida at the moment. I'm also a bit concerned because what this pipeline needs now most is more tests, bug fixes and cleaning up a couple of things before adding new features.

Would you be interested in working on this in a pull request?

Best,
Gregor

@vd4mmind
Copy link

vd4mmind commented Jul 5, 2024

Hi @grst and @fmalmeida ,

Thank you very much for the response and we really appreciate all the amazing work you all have done on this repository.

@NNazeu , @herpov and me have been using different versions of the pipeline at our end and testing them as we plan to use it for an upcoming clinical trial where 5' Chromium Single Cell Immune Profiling is a primary end-point for drug MoA. We have been trying to reach towards a more compiant ready version using the versions in place. We have tested with a PR branch before and also a few of your PROD versions as they got updated, however, we are not nextflow experts, also not entirely familiar with the best practises and ways of working in terms of development. We can definitely work with you on a PR, clarify the requirements, if this can be implemented at your end, we can review and do the necessary testing to facilitate this to make it more streamlined. We will need some clarity from your end to understand which submodule this implementation will be needed since looking into the git repo and the structure, we have some understanding but not entirely sure given our lack of nf-core development standards and experience, so we would not like to make any guesses. We also have the test data ready in formats that can be used, can share it with you guys and also prepare relevant formats (samplesheet) needed for implementation.

If either of you think this is feasbile and we can collaborate around data prep, review and testing from our end, it would be great to get this done. Let us know what you think and how would you like to proceed. Thanks again for taking time to respond and helping this far with the pipeline.

Kind regards,

Vivek

on behalf of the singel cell omics team

@grst
Copy link
Member

grst commented Jul 12, 2024

Hi @vd4mmind,

I'm afraid neither Felip nor myself currently have the time to support this feature. I provided some more details via PM on the nf-core slack.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

5 participants