add gatk dict to create dictionnary from fasta file

This commit is contained in:
MaxUlysse 2020-01-23 11:35:19 +01:00
parent a69aebd01b
commit 9db873c3bc
4 changed files with 59 additions and 0 deletions

19
tools/gatk/dict/main.nf Normal file
View file

@ -0,0 +1,19 @@
process gatk_dict {
tag {fasta}
container 'quay.io/biocontainers/gatk4-spark:4.1.4.1--1'
input:
path(fasta)
output:
path("${fasta.baseName}.dict")
script:
"""
gatk --java-options "-Xmx${task.memory.toGiga()}g" \
CreateSequenceDictionary \
--REFERENCE ${fasta} \
--OUTPUT ${fasta.baseName}.dict
"""
}

25
tools/gatk/dict/meta.yml Normal file
View file

@ -0,0 +1,25 @@
name: gatk dict
description: create a dictionary file from a fasta file
keywords:
- dictionary
tools:
- gatk:
description: |
The GATK toolkit offers a wide variety of tools with a primary focus on variant discovery and genotyping, developed in the Data Sciences Platform at the Broad Institute.
homepage: https://gatk.broadinstitute.org/hc/en-us
documentation: https://gatk.broadinstitute.org/hc/en-us/categories/360002369672s
doi: 10.1158/1538-7445.AM2017-3590
input:
-
- input:
type: file
description: Input fasta file
pattern: *.{fasta,fa}
output:
-
- dict:
type: file
description: gatk dictionary file
pattern: *.{fasta,fa}.{dict}
authors:
- @maxulysse

View file

@ -0,0 +1,13 @@
#!/usr/bin/env nextflow
nextflow.preview.dsl = 2
include '../../../nf-core/module_testing/check_process_outputs.nf' params(params)
include '../main.nf' params(params)
// Define input channels
input = '../../../test-datasets/tools/bwa/index/input/reference.fasta'
// Run the workflow
workflow {
gatk_dict(input)
// .check_output()
}

View file

@ -0,0 +1,2 @@
docker.enabled = true
params.outdir = './results'