Merge branch '19868-pca-in-ml' into main
[lightning.git] / cwl / gvcf2fasta / get_bed_varonlyvcf.cwl
1 # Copyright (C) The Lightning Authors. All rights reserved.
2 #
3 # SPDX-License-Identifier: AGPL-3.0
4
5 cwlVersion: v1.1
6 class: CommandLineTool
7 label: Get no call BED and variant only VCF from gVCF
8 requirements:
9   ShellCommandRequirement: {}
10 hints:
11   DockerRequirement:
12     dockerPull: vcfutil
13   ResourceRequirement:
14     ramMin: 5000
15     outdirMin: 40000
16 inputs:
17   sampleid:
18     type: string
19     label: Sample ID
20   vcf:
21     type: File
22     label: Input gVCF
23   gqcutoff:
24     type: int
25     label: GQ (Genotype Quality) cutoff for filtering  
26   genomebed:
27     type: File
28     label: Whole genome BED
29 outputs:
30   nocallbed:
31     type: File
32     label: No call BED of gVCF
33     outputBinding:
34       glob: "*_nocall.bed"
35   varonlyvcf:
36     type: File
37     label: Variant only VCF
38     outputBinding:
39       glob: "*_varonly.vcf.gz"
40     secondaryFiles: [.tbi]
41 baseCommand: /gvcf_regions/gvcf_regions.py
42 arguments:
43   - prefix: "--min_GQ"
44     valueFrom: $(inputs.gqcutoff)
45   - $(inputs.vcf)
46   - shellQuote: False
47     valueFrom: ">"
48   - $(inputs.sampleid).bed
49   - shellQuote: False
50     valueFrom: "&&"
51   - "bedtools"
52   - "subtract"
53   - prefix: "-a"
54     valueFrom: $(inputs.genomebed)
55   - prefix: "-b"
56     valueFrom: $(inputs.sampleid).bed
57   - shellQuote: False
58     valueFrom: ">"
59   - $(inputs.sampleid)_nocall.bed
60   - shellQuote: False
61     valueFrom: "&&"
62   - "bgzip"
63   - "-dc"
64   - $(inputs.vcf)
65   - shellQuote: False
66     valueFrom: "|"
67   - "grep"
68   - "-v"
69   - "END="
70   - shellQuote: False
71     valueFrom: "|"
72   - "bgzip"
73   - "-c"
74   - shellQuote: False
75     valueFrom: ">"
76   - $(inputs.sampleid)_varonly.vcf.gz
77   - shellQuote: False
78     valueFrom: "&&"
79   - "tabix"
80   - $(inputs.sampleid)_varonly.vcf.gz