I am unable to successfully run this small snakemake program for StringTie; the dry-run gives an error of MissingInputException for the "rule stringt", I am unable to understand the issue here since the same directory structures works fine for a different snakemake program.
I have already generated the bam files using "hisat2" and is located in the directory : "/alternate_splice/bam_out/" which is stored as " bamdir". The snakemake should be able to locate the input file since the names and location are appropriate, however it throws an error every time. I dont have anyone in my group who works with Snakemake or can help me.
If anyone can help me out here, it would be great!
There are 4 samples: for the wildcards, it takes the list from the directory which has the fastq files
-rw-r--r-- 1 shivani domain^users 1306438351 Jan 2 09:46 TL-19-DA4299_T_RSQ1_2.fastq.gz
-rw-r--r-- 1 shivani domain^users 1185743896 Jan 2 09:46 TL-19-DA4299_T_RSQ1_1.fastq.gz
-rw-r--r-- 1 shivani domain^users 1896352262 Jan 9 08:49 TL-20-24D57D_T_RSQ1_2.fastq.gz
-rw-r--r-- 1 shivani domain^users 1730191383 Jan 9 08:49 TL-20-24D57D_T_RSQ1_1.fastq.gz
-rwxr-xr-x 1 shivani domain^users 3215901253 Mar 25 10:28 BREAST_817_N1_RNA_REP1_1.fastq.gz
-rwxr-xr-x 1 shivani domain^users 3396212102 Mar 25 10:36 BREAST_817_N1_RNA_REP1_2.fastq.gz
-rwxr-xr-x 1 shivani domain^users 3633768287 Mar 25 10:45 BREAST_792_N1_RNA_REP1_1.fastq.gz
-rwxr-xr-x 1 shivani domain^users 3932340643 Mar 25 10:54 BREAST_792_N1_RNA_REP1_2.fastq.gz
(SAMPLE,)=glob_wildcards("/home/shivani/alternate_splice/expdata/{sample}_1.fastq.gz")
#(SAMPLE,)=glob_wildcards("/home/shivani/alternate_splice/bam_out/{sample}.bam")
bamdir = "/home/shivani/alternate_splice/bam_out/"
refere_genome = "/home/shivani/ccb1_shivani/hisat2_trans_bam/hisat2_index/"
geneGTF = "/home/shivani/stringtie_run/Homo_sapiens.GRCh37.87.gtf"
rule all:
input:
expand(bamdir+"{sample}_transcript.gft",sample=SAMPLE),
expand(bamdir+"{sample}_abundance.tsv",sample=SAMPLE),
expand(bamdir+"{sample}_coverage.gtf",sample=SAMPLE)
expand(bamdir+"{sample}_stringtie_merge.gtf",sample=SAMPLE)
rule stringt:
input:
bm=bamdir+"{sample}.bam",
gtf=geneGTF,
tname="{sample}"
output:
tscripts=bamdir+"{sample}_transcript.gft",
abund=bamdir+"{sample}_abundance.tsv",
cov=bamdir+"{sample}_coverage.gtf"
shell:
"""stringtie -p 4 -e -c 3.5 -G {input.gtf} -o {output.tscripts} -A {output.abund} -C {output.cov} -l {sample}{input.bm}"""
rule merge:
input:
trnsgtf=bamdir+"{sample}_transcript.gft",
ggtf=geneGTF
output :bamdir+"{sample}_stringtie_merge.gtf"
shell:"stringtie -p 4 --merge -G {input.ggtf} -o {output} {input.trnsgtf}"
Error message ::: (spladder_run) shivani@ccb2:~/alternate_splice$ snakemake -n -r -s stringtie_trans
Building DAG of jobs...
MissingInputException in line 20 of /home/shivani/alternate_splice/stringtie_trans: Missing input files for rule stringt: BREAST_792_N1_RNA_REP1
Yes, I did that and it worked, thanks!