assembly.smk 1.1 KB
Newer Older
Jan Hoeckesfeld's avatar
Jan Hoeckesfeld committed
1
2
3
4
5
6
7
8
9
10
11
12
rule spades:
    input:
        read1 = 'data/auxiliary/' + config['input_folder'] + '/{id}' + '.qc' + config['input_read_1_ending'],
        read2 = 'data/auxiliary/' + config['input_folder'] + '/{id}' + '.qc' + config['input_read_2_ending']
    output:
        directory('data/auxiliary/' + config['input_folder'] + '/{id}/spades')
    singularity:
        'docker://pegi3s/spades:latest'
    shell:
        'spades.py -1 {input.read1} -2 {input.read2} -o {output} --phred-offset 33' + (
        (' --trusted-contigs ' + 'data/input/' + config['reference_genome'] + '/' + config['genome_file_identifier']) if
        config['reference_guided_assembly'] else '')
Philipp Spohr's avatar
Philipp Spohr committed
13

Jan Hoeckesfeld's avatar
Jan Hoeckesfeld committed
14
15
16
17
18
19
20
21
22
23
24
25
rule exactMatch:
    input:
        infolder = 'data/auxiliary/' + config['input_folder'] + '/{id}/spades'
    output:
        'data/output/' + config['input_folder'] + '/{id}/exactMatches.tsv'
    params:
        spaSeqs = 'data/auxiliary/spaSequences.fa',
        scaffolds = 'data/auxiliary/' + config['input_folder'] + '/{id}/spades/scaffolds.fasta'
    conda:
        '../envs/biopythonworkbench.yaml'
    script:
        '../scripts/spaSequenceSearch.py'