forked from nf-core/phaseimpute
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request nf-core#40 from atrigila/add_tool_stitch
Add tool stitch
- Loading branch information
Showing
34 changed files
with
1,173 additions
and
388 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,3 @@ | ||
repository_type: pipeline | ||
lint: | ||
subworkflow_changes: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
{ | ||
"$schema": "http://json-schema.org/draft-07/schema", | ||
"$id": "https://raw.githubusercontent.com/nf-core/phaseimpute/master/assets/schema_posfile.json", | ||
"title": "nf-core/phaseimpute pipeline - params.posfile schema", | ||
"description": "Schema for the file provided with params.posfile", | ||
"type": "array", | ||
"items": { | ||
"type": "object", | ||
"properties": { | ||
"chr": { | ||
"type": "string", | ||
"pattern": "^\\S+$", | ||
"errorMessage": "Chromosome name must be provided as a string and cannot contain spaces", | ||
"meta": ["chr"] | ||
}, | ||
"file": { | ||
"type": "string", | ||
"pattern": "^\\S+\\.txt$", | ||
"errorMessage": "Posfile per chromosome must be provided. Must have .txt extension" | ||
} | ||
}, | ||
"required": ["chr", "file"] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,111 @@ | ||
/* | ||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
Config file for defining DSL2 per module options and publishing paths | ||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
Available keys to override module options: | ||
ext.args = Additional arguments appended to command in module. | ||
ext.args2 = Second set of arguments appended to command in module (multi-tool modules). | ||
ext.args3 = Third set of arguments appended to command in module (multi-tool modules). | ||
ext.prefix = File name prefix for output files. | ||
---------------------------------------------------------------------------------------- | ||
*/ | ||
|
||
process { | ||
|
||
withName: CUSTOM_DUMPSOFTWAREVERSIONS { | ||
publishDir = [ | ||
path: { "${params.outdir}/pipeline_info" }, | ||
mode: params.publish_dir_mode, | ||
pattern: '*_versions.yml' | ||
] | ||
} | ||
|
||
withName: 'NFCORE_PHASEIMPUTE:PHASEIMPUTE:PREPARE_POSFILE_TSV:.*' { | ||
publishDir = [ | ||
path: { "${params.outdir}/prep_panel/posfile/" }, | ||
mode: params.publish_dir_mode, | ||
enabled: true | ||
] | ||
} | ||
|
||
withName: 'NFCORE_PHASEIMPUTE:PHASEIMPUTE:PREPARE_POSFILE_TSV:GAWK' { | ||
ext.args = "'{ key = \$1 FS \$2 } !seen[key]++'" | ||
ext.prefix = { "${meta.id}_${meta.chr}_posfile_stitch" } | ||
ext.suffix = ".txt" | ||
} | ||
|
||
withName: 'NFCORE_PHASEIMPUTE:PHASEIMPUTE:PREPARE_INPUT_STITCH:BCFTOOLS_NORM' { | ||
ext.args = '-m +any --output-type z' | ||
ext.prefix = { "${meta.id}_${meta.chr}_multiallelic" } | ||
maxRetries = 2 | ||
publishDir = [enabled: false] | ||
} | ||
|
||
withName: 'NFCORE_PHASEIMPUTE:PHASEIMPUTE:PREPARE_INPUT_STITCH:BCFTOOLS_VIEW' { | ||
ext.args = '-v snps -Oz' | ||
ext.prefix = { "${meta.id}_${meta.chr}_biallelic" } | ||
maxRetries = 2 | ||
publishDir = [enabled: false] | ||
|
||
} | ||
|
||
withName: 'NFCORE_PHASEIMPUTE:PHASEIMPUTE:PREPARE_INPUT_STITCH:BCFTOOLS_INDEX' { | ||
maxRetries = 2 | ||
publishDir = [enabled: false] | ||
|
||
} | ||
|
||
withName: 'NFCORE_PHASEIMPUTE:PHASEIMPUTE:PREPARE_INPUT_STITCH:BCFTOOLS_INDEX_2' { | ||
ext.args = '--tbi' | ||
maxRetries = 2 | ||
publishDir = [enabled: false] | ||
|
||
} | ||
|
||
withName: 'NFCORE_PHASEIMPUTE:PHASEIMPUTE:PREPARE_POSFILE_TSV:BCFTOOLS_QUERY' { | ||
ext.args = [ | ||
"-f'%CHROM\t%POS\t%REF\t%ALT\\n'", | ||
].join(' ') | ||
ext.prefix = { "${meta.id}_${meta.chr}_posfile_stitch" } | ||
publishDir = [enabled: false] | ||
} | ||
|
||
withName: 'NFCORE_PHASEIMPUTE:PHASEIMPUTE:BAM_IMPUTE_STITCH:.*' { | ||
publishDir = [ | ||
path: { "${params.outdir}/imputation/stitch/" }, | ||
mode: params.publish_dir_mode, | ||
enabled: true | ||
] | ||
} | ||
|
||
withName: 'NFCORE_PHASEIMPUTE:PHASEIMPUTE:BAM_IMPUTE_STITCH:BCFTOOLS_INDEX' { | ||
ext.args = '--tbi' | ||
maxRetries = 2 | ||
publishDir = [enabled: false] | ||
} | ||
|
||
withName: 'NFCORE_PHASEIMPUTE:PHASEIMPUTE:CONCAT_STITCH:.*' { | ||
publishDir = [ | ||
[ | ||
path: { "${params.outdir}/imputation/stitch/concat" }, | ||
mode: params.publish_dir_mode, | ||
], | ||
] | ||
} | ||
|
||
withName: 'NFCORE_PHASEIMPUTE:PHASEIMPUTE:CONCAT_STITCH:BCFTOOLS_CONCAT' { | ||
ext.args = {[ | ||
"--ligate", | ||
"--output-type z", | ||
].join(" ").trim()} | ||
ext.prefix = { "${meta.id}_stitch" } | ||
} | ||
|
||
withName: 'NFCORE_PHASEIMPUTE:PHASEIMPUTE:CONCAT_STITCH:BCFTOOLS_INDEX' { | ||
ext.args = "--tbi" | ||
ext.prefix = { "${meta.id}_stitch" } | ||
} | ||
|
||
|
||
|
||
} |
Oops, something went wrong.