snakemake-workflows / rna-seq-star-deseq2

RNA-seq workflow using STAR and DESeq2
MIT License
327 stars 203 forks source link

Confusion about the trimming for single-end data #4

Closed john-lee-johnson closed 6 years ago

john-lee-johnson commented 6 years ago

Hello,

I am new to snakemake and very eager to learn more.

I am trying to play with this workflow to learn more about how to properly use snakemake and I'm using data from GEO, I'm a little stuck on the trimming step. There are two rules, one for paired-end trimming, and one for single-end trimming. I have single-end data, but the paired-end trimming rule is only getting called. My units.tsv file looks like this:

sample unit fq1 fq2
GSM945742 SRR504812 SRR504812.fastq
GSM945741 SRR504810 SRR504810.fastq
GSM945741 SRR504811 SRR504811.fastq

and the results of snakemake -np for one of the fastq files show that it's calling the paired-end rule. My question is, how can I make the workflow call the appropriate rule here?

rule cutadapt_pe:
    input: SRR504811.fastq
    output: trimmed/GSM945741-SRR504811.1.fastq.gz, trimmed/GSM945741-SRR504811.2.fastq.gz, trimmed/GSM945741-SRR504811.qc.txt
    log: logs/cutadapt/GSM945741-SRR504811.log
    jobid: 19
    wildcards: sample=GSM945741, unit=SRR504811

Thank you, I'm sorry if this is a dumb question

johanneskoester commented 6 years ago

Thanks for reporting. This might be a bug. Of course, the workflow should automatically select the right rule. Actually our test case only consists of paired end data. I will have a look tomorrow.

johanneskoester commented 6 years ago

This is now fixed in the master branch.