Snakemake: Missing output files:
1
0
Entering edit mode
5.0 years ago
Jiji • 0

Hi there,

I have been trying to run the Snakemake tutorial with the following:

rule bwa_map:
  input:
    "data/genome.fa",
    "data/samples/A.fastq"
  output:
    "mapped_reads/A.bam"
  shell:
    "bwa mem {input} | samtools view -Sb -> {output}"

However, I am getting the error Missing output files: mapped_reads/A.bam when run with the following: snakemake -n -r

Any advice is greatly appreciated. Thank you.

snakemake • 5.2k views
ADD COMMENT
1
Entering edit mode

Maybe try changing "->" to ">" in your shell command ?

ADD REPLY
0
Entering edit mode

Thank you for looking into this.

ADD REPLY
1
Entering edit mode
5.0 years ago

Hi, this error tells that pipeline finished but files are not found where those are expected. With such pipes you lose all error handlings and it is not clear which command failed. For bwa mem index file is needed. Therefore it should also be included in input of this rule. But then you would need to pass inputsto shell command by providing index of the list: {input[0]} Or name those inputs as python variables for snakemake: input: index = "path/to/inputfile_index", ...

Other than this it is hard to tell what went wrong w/o full error msg.

ADD COMMENT
0
Entering edit mode

Thank you. This solved the problem.

ADD REPLY

Login before adding your answer.

Traffic: 1972 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6