-
Notifications
You must be signed in to change notification settings - Fork 41
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 #382 from nf-core/issue_370
POC contrasts csv -> yaml
- Loading branch information
Showing
12 changed files
with
1,174 additions
and
9 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,6 +8,7 @@ on: | |
branches: | ||
- dev | ||
- master | ||
- dev_tmp | ||
release: | ||
types: [published] | ||
workflow_dispatch: | ||
|
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
Large diffs are not rendered by default.
Oops, something went wrong.
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,5 @@ | ||
channels: | ||
- conda-forge | ||
- bioconda | ||
dependencies: | ||
- bioconda::r-shinyngs=2.0.0 |
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,45 @@ | ||
process SHINYNGS_VALIDATEFOMCOMPONENTS { //TODO this module and whole folder should be deleted once https://github.com/nf-core/differentialabundance/issues/362 is closed, is replaced by the nf-core version of it. | ||
tag "$sample" | ||
label 'process_single' | ||
|
||
conda "${moduleDir}/environment.yml" | ||
container "community.wave.seqera.io/library/r-shinyngs_r-yaml:aa63537f6db6190c" | ||
|
||
input: | ||
tuple val(meta), path(sample), path(assay_files) | ||
tuple val(meta2), path(feature_meta) | ||
tuple val(meta3), path(contrasts) | ||
|
||
output: | ||
tuple val(meta), path("*/*.sample_metadata.tsv") , emit: sample_meta | ||
tuple val(meta), path("*/*.feature_metadata.tsv") , emit: feature_meta, optional: true | ||
tuple val(meta), path("*/*.assay.tsv") , emit: assays | ||
tuple val(meta), path("*/*.contrasts_file.tsv") , emit: contrasts | ||
path "versions.yml" , emit: versions | ||
|
||
when: | ||
task.ext.when == null || task.ext.when | ||
|
||
script: | ||
// For full list of available args see | ||
// https://github.com/pinin4fjords/shinyngs/blob/develop/exec/validate_fom_components.R | ||
def args = task.ext.args ?: '' | ||
def prefix = task.ext.prefix ?: meta.id | ||
def feature = feature_meta ? "--feature_metadata '$feature_meta'" : '' | ||
|
||
""" | ||
validate_fom_components_yaml.R \\ | ||
--sample_metadata "$sample" \\ | ||
$feature \\ | ||
--assay_files "${assay_files.join(',')}" \\ | ||
--contrasts_file "$contrasts" \\ | ||
--output_directory "$prefix" \\ | ||
$args | ||
cat <<-END_VERSIONS > versions.yml | ||
"${task.process}": | ||
r-base: \$(echo \$(R --version 2>&1) | sed 's/^.*R version //; s/ .*\$//') | ||
r-shinyngs: \$(Rscript -e "library(shinyngs); cat(as.character(packageVersion('shinyngs')))") | ||
END_VERSIONS | ||
""" | ||
} |
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,100 @@ | ||
name: "shinyngs_validatefomcomponents" | ||
description: validate consistency of feature and sample annotations with matrices | ||
and contrasts | ||
keywords: | ||
- expression | ||
- features | ||
- observations | ||
- validation | ||
tools: | ||
- "shinyngs": | ||
description: "Provides Shiny applications for various array and NGS applications. | ||
Currently very RNA-seq centric, with plans for expansion." | ||
homepage: "https://github.com/pinin4fjords/shinyngs" | ||
documentation: "https://rawgit.com/pinin4fjords/shinyngs/master/vignettes/shinyngs.html" | ||
tool_dev_url: "https://github.com/pinin4fjords/shinyngs" | ||
licence: ["AGPL v3"] | ||
identifier: "" | ||
input: | ||
- - meta: | ||
type: map | ||
description: | | ||
Groovy Map containing information on experiment, at a minimum an id. | ||
e.g. [ id:'test' ] | ||
- sample: | ||
type: file | ||
description: | | ||
CSV-format sample sheet with sample metadata | ||
- assay_files: | ||
type: file | ||
description: | | ||
List of TSV-format matrix files representing different measures for the same samples (e.g. raw and normalised). | ||
- - meta2: | ||
type: map | ||
description: | | ||
Groovy Map containing information on features. | ||
e.g. [ id:'test' ] | ||
- feature_meta: | ||
type: file | ||
description: | | ||
TSV-format feature (e.g. gene) metadata | ||
- - meta3: | ||
type: map | ||
description: | | ||
Groovy Map containing information on contrasts. | ||
e.g. [ id:'test' ] | ||
- contrasts: | ||
type: file | ||
description: | | ||
CSV-format file with four columns identifying the sample sheet variable, reference level, treatment level, and optionally a comma-separated list of covariates used as blocking factors. | ||
output: | ||
- sample_meta: | ||
- meta: | ||
type: map | ||
description: | | ||
Groovy Map containing information on experiment. | ||
e.g. [ id:'test' ] | ||
- "*/*.sample_metadata.tsv": | ||
type: file | ||
description: File containing validated sample metadata | ||
pattern: "/*.sample_metadata.tsv" | ||
- feature_meta: | ||
- meta: | ||
type: map | ||
description: | | ||
Groovy Map containing information on experiment. | ||
e.g. [ id:'test' ] | ||
- "*/*.feature_metadata.tsv": | ||
type: file | ||
description: File containing validated feature metadata | ||
pattern: "/*.feature_metadata.tsv" | ||
optional: true | ||
- assays: | ||
- meta: | ||
type: map | ||
description: | | ||
Groovy Map containing information on experiment. | ||
e.g. [ id:'test' ] | ||
- "*/*.assay.tsv": | ||
type: file | ||
description: Files containing validated matrices | ||
pattern: "/*.assay.tsv" | ||
- contrasts: | ||
- meta: | ||
type: map | ||
description: | | ||
Groovy Map containing information on experiment. | ||
e.g. [ id:'test' ] | ||
- "*/*.contrasts_file.tsv": | ||
type: file | ||
description: Files containing validated matrices | ||
pattern: "/*.contrasts_file.tsv" | ||
- versions: | ||
- versions.yml: | ||
type: file | ||
description: File containing software versions | ||
pattern: "versions.yml" | ||
authors: | ||
- "@pinin4fjords" | ||
maintainers: | ||
- "@pinin4fjords" |
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
Oops, something went wrong.