Question: Filtering paired reads when forward is all scRNA-seq barcode sequence
gravatar for connor.driscoll88
2.2 years ago by
connor.driscoll880 wrote:

Hi all,

I have paired-end fastq files from a single-cell RNA seq experiment. The forward files consist of barcode reads (no usable sequence information) while the reverse reads contain transcript sequences. I'm looking for an efficient way to filter out rRNA reads, but it's a little tricky considering I can't align the forward reads. Is there an efficient way of doing this either within an aligner or with a quick downstream script that will result in rRNA-filtered and orphanless paired end (non-interleaved) fastq files?


rna-seq alignment scrna-seq • 673 views
ADD COMMENTlink modified 2.1 years ago by Biostar ♦♦ 20 • written 2.2 years ago by connor.driscoll880
gravatar for Pierre Lindenbaum
2.2 years ago by
France/Nantes/Institut du Thorax - INSERM UMR1087
Pierre Lindenbaum134k wrote:

but it's a little tricky considering I can't align the forward reads.

so R1 won't be mapped but R2 will. And then filter with samtools

ADD COMMENTlink written 2.2 years ago by Pierre Lindenbaum134k

Ah, I see that is quite simple! So the correct samtools flag be 9 (read paired (0x1) & mate unmapped (0x8))?

Edit: Okay, I think it should be 13 (read paired (0x1) & read unmapped (0x4) & mate unmapped (0x8)) since the read 1 is the "read" and read 2 is the "mate." Also, I want the mates which are unmapped.

Edit 2: If anyone is interested, here is what I used to convert sam output to bam, filter only for pairs where reverse read non-mapped, and converted back to two non-interleaved fastqs in a single command:

samtools view -bS input.sam | samtools view -u -f 13 - | samtools fastq -1 input.norRNA_R1.fastq.gz -2 input.norRNA_R2.fastq.gz -
ADD REPLYlink modified 2.2 years ago • written 2.2 years ago by connor.driscoll880
Please log in to add an answer.


Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 1995 users visited in the last hour