Build branch main with version main (1d87dc7)

Build pipeline: viash-hub.rnaseq.main-g2rlq

Source commit: 1d87dc7c24

Source message: Multiple fixes (#23)

* multiple fixes

* update arguments and add test

* fix biobox module calls

* fix dependency

* add rsem merge counts

* exclude general stats in multiqc report

* output markduplicates metrics

* rename output reference files
This commit is contained in:
CI
2024-10-01 10:12:28 +00:00
parent 9b29e37466
commit c106022744
237 changed files with 9490 additions and 2187 deletions

View File

@@ -193,7 +193,7 @@ argument_groups:
multiple: false
multiple_sep: ";"
- type: "string"
name: "extra_rsem_calculate_expression_args"
name: "--extra_rsem_calculate_expression_args"
description: "Extra arguments to pass to rsem-calculate-expression command in\
\ addition to defaults defined by the pipeline."
info: null
@@ -242,7 +242,7 @@ argument_groups:
name: "--star_multiqc"
info: null
default:
- "$id.star_align.log"
- "$id_star.log"
must_exist: true
create_parent: true
required: false
@@ -381,6 +381,87 @@ argument_groups:
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--salmon_multiqc"
info: null
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--rsem_counts_gene"
description: "Expression counts on gene level"
info: null
default:
- "$id.genes.results"
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--counts_transcripts"
description: "Expression counts on transcript level"
info: null
default:
- "$id.isoforms.results"
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--rsem_multiqc"
description: "RSEM statistics"
info: null
default:
- "$id.stat"
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--bam_star_rsem"
description: "BAM file generated by STAR (optional)"
info: null
default:
- "$id.STAR.genome.bam"
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--bam_genome_rsem"
description: "Genome BAM file (optional)"
info: null
default:
- "$id.genome.bam"
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--bam_transcript_rsem"
description: "Transcript BAM file (optional)"
info: null
default:
- "$id.transcript.bam"
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
resources:
- type: "nextflow_script"
path: "main.nf"
@@ -522,8 +603,8 @@ build_info:
output: "target/executable/workflows/genome_alignment_and_quant"
executable: "target/executable/workflows/genome_alignment_and_quant/genome_alignment_and_quant"
viash_version: "0.9.0"
git_commit: "64aad6a006818388eceffe024b1701b3eae06bee"
git_remote: "https://x-access-token:ghs_sq8cBpPtIm1wZvLlQUshbKRwwqLLDl0UmbNu@github.com/viash-hub/rnaseq"
git_commit: "1d87dc7c24f540c96460e69322f06d4be0bb7be8"
git_remote: "https://x-access-token:ghs_vs3fpTo1mWGISEIj2mqOUQA3IRBYZ30EQLHG@github.com/viash-hub/rnaseq"
dependencies:
- "target/dependencies/vsh/vsh/biobox/v0.2.0/nextflow/star/star_align_reads"
- "target/dependencies/vsh/vsh/biobox/v0.2.0/nextflow/samtools/samtools_sort"

View File

@@ -268,7 +268,7 @@ function ViashHelp {
echo " By default, the pipeline uses the gene_name field to obtain additional"
echo " gene identifiers from the input GTF file when running Salmon."
echo ""
echo " extra_rsem_calculate_expression_args"
echo " --extra_rsem_calculate_expression_args"
echo " type: string"
echo " Extra arguments to pass to rsem-calculate-expression command in addition"
echo " to defaults defined by the pipeline."
@@ -291,7 +291,7 @@ function ViashHelp {
echo "Output:"
echo " --star_multiqc"
echo " type: file, output, file must exist"
echo " default: \$id.star_align.log"
echo " default: \$id_star.log"
echo ""
echo " --genome_bam_sorted"
echo " type: file, output, file must exist"
@@ -340,6 +340,39 @@ function ViashHelp {
echo " --quant_results_file"
echo " type: file, output, file must exist"
echo " default: \$id.quant.sf"
echo ""
echo " --salmon_multiqc"
echo " type: file, output, file must exist"
echo ""
echo " --rsem_counts_gene"
echo " type: file, output, file must exist"
echo " default: \$id.genes.results"
echo " Expression counts on gene level"
echo ""
echo " --counts_transcripts"
echo " type: file, output, file must exist"
echo " default: \$id.isoforms.results"
echo " Expression counts on transcript level"
echo ""
echo " --rsem_multiqc"
echo " type: file, output, file must exist"
echo " default: \$id.stat"
echo " RSEM statistics"
echo ""
echo " --bam_star_rsem"
echo " type: file, output, file must exist"
echo " default: \$id.STAR.genome.bam"
echo " BAM file generated by STAR (optional)"
echo ""
echo " --bam_genome_rsem"
echo " type: file, output, file must exist"
echo " default: \$id.genome.bam"
echo " Genome BAM file (optional)"
echo ""
echo " --bam_transcript_rsem"
echo " type: file, output, file must exist"
echo " default: \$id.transcript.bam"
echo " Transcript BAM file (optional)"
}
# initialise variables
@@ -575,6 +608,17 @@ while [[ $# -gt 0 ]]; do
VIASH_PAR_GTF_EXTRA_ATTRIBUTES=$(ViashRemoveFlags "$1")
shift 1
;;
--extra_rsem_calculate_expression_args)
[ -n "$VIASH_PAR_EXTRA_RSEM_CALCULATE_EXPRESSION_ARGS" ] && ViashError Bad arguments for option \'--extra_rsem_calculate_expression_args\': \'$VIASH_PAR_EXTRA_RSEM_CALCULATE_EXPRESSION_ARGS\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_EXTRA_RSEM_CALCULATE_EXPRESSION_ARGS="$2"
[ $# -lt 2 ] && ViashError Not enough arguments passed to --extra_rsem_calculate_expression_args. Use "--help" to get more information on the parameters. && exit 1
shift 2
;;
--extra_rsem_calculate_expression_args=*)
[ -n "$VIASH_PAR_EXTRA_RSEM_CALCULATE_EXPRESSION_ARGS" ] && ViashError Bad arguments for option \'--extra_rsem_calculate_expression_args=*\': \'$VIASH_PAR_EXTRA_RSEM_CALCULATE_EXPRESSION_ARGS\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_EXTRA_RSEM_CALCULATE_EXPRESSION_ARGS=$(ViashRemoveFlags "$1")
shift 1
;;
--aligner)
[ -n "$VIASH_PAR_ALIGNER" ] && ViashError Bad arguments for option \'--aligner\': \'$VIASH_PAR_ALIGNER\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_ALIGNER="$2"
@@ -751,6 +795,83 @@ while [[ $# -gt 0 ]]; do
VIASH_PAR_QUANT_RESULTS_FILE=$(ViashRemoveFlags "$1")
shift 1
;;
--salmon_multiqc)
[ -n "$VIASH_PAR_SALMON_MULTIQC" ] && ViashError Bad arguments for option \'--salmon_multiqc\': \'$VIASH_PAR_SALMON_MULTIQC\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_SALMON_MULTIQC="$2"
[ $# -lt 2 ] && ViashError Not enough arguments passed to --salmon_multiqc. Use "--help" to get more information on the parameters. && exit 1
shift 2
;;
--salmon_multiqc=*)
[ -n "$VIASH_PAR_SALMON_MULTIQC" ] && ViashError Bad arguments for option \'--salmon_multiqc=*\': \'$VIASH_PAR_SALMON_MULTIQC\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_SALMON_MULTIQC=$(ViashRemoveFlags "$1")
shift 1
;;
--rsem_counts_gene)
[ -n "$VIASH_PAR_RSEM_COUNTS_GENE" ] && ViashError Bad arguments for option \'--rsem_counts_gene\': \'$VIASH_PAR_RSEM_COUNTS_GENE\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_RSEM_COUNTS_GENE="$2"
[ $# -lt 2 ] && ViashError Not enough arguments passed to --rsem_counts_gene. Use "--help" to get more information on the parameters. && exit 1
shift 2
;;
--rsem_counts_gene=*)
[ -n "$VIASH_PAR_RSEM_COUNTS_GENE" ] && ViashError Bad arguments for option \'--rsem_counts_gene=*\': \'$VIASH_PAR_RSEM_COUNTS_GENE\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_RSEM_COUNTS_GENE=$(ViashRemoveFlags "$1")
shift 1
;;
--counts_transcripts)
[ -n "$VIASH_PAR_COUNTS_TRANSCRIPTS" ] && ViashError Bad arguments for option \'--counts_transcripts\': \'$VIASH_PAR_COUNTS_TRANSCRIPTS\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_COUNTS_TRANSCRIPTS="$2"
[ $# -lt 2 ] && ViashError Not enough arguments passed to --counts_transcripts. Use "--help" to get more information on the parameters. && exit 1
shift 2
;;
--counts_transcripts=*)
[ -n "$VIASH_PAR_COUNTS_TRANSCRIPTS" ] && ViashError Bad arguments for option \'--counts_transcripts=*\': \'$VIASH_PAR_COUNTS_TRANSCRIPTS\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_COUNTS_TRANSCRIPTS=$(ViashRemoveFlags "$1")
shift 1
;;
--rsem_multiqc)
[ -n "$VIASH_PAR_RSEM_MULTIQC" ] && ViashError Bad arguments for option \'--rsem_multiqc\': \'$VIASH_PAR_RSEM_MULTIQC\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_RSEM_MULTIQC="$2"
[ $# -lt 2 ] && ViashError Not enough arguments passed to --rsem_multiqc. Use "--help" to get more information on the parameters. && exit 1
shift 2
;;
--rsem_multiqc=*)
[ -n "$VIASH_PAR_RSEM_MULTIQC" ] && ViashError Bad arguments for option \'--rsem_multiqc=*\': \'$VIASH_PAR_RSEM_MULTIQC\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_RSEM_MULTIQC=$(ViashRemoveFlags "$1")
shift 1
;;
--bam_star_rsem)
[ -n "$VIASH_PAR_BAM_STAR_RSEM" ] && ViashError Bad arguments for option \'--bam_star_rsem\': \'$VIASH_PAR_BAM_STAR_RSEM\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_BAM_STAR_RSEM="$2"
[ $# -lt 2 ] && ViashError Not enough arguments passed to --bam_star_rsem. Use "--help" to get more information on the parameters. && exit 1
shift 2
;;
--bam_star_rsem=*)
[ -n "$VIASH_PAR_BAM_STAR_RSEM" ] && ViashError Bad arguments for option \'--bam_star_rsem=*\': \'$VIASH_PAR_BAM_STAR_RSEM\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_BAM_STAR_RSEM=$(ViashRemoveFlags "$1")
shift 1
;;
--bam_genome_rsem)
[ -n "$VIASH_PAR_BAM_GENOME_RSEM" ] && ViashError Bad arguments for option \'--bam_genome_rsem\': \'$VIASH_PAR_BAM_GENOME_RSEM\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_BAM_GENOME_RSEM="$2"
[ $# -lt 2 ] && ViashError Not enough arguments passed to --bam_genome_rsem. Use "--help" to get more information on the parameters. && exit 1
shift 2
;;
--bam_genome_rsem=*)
[ -n "$VIASH_PAR_BAM_GENOME_RSEM" ] && ViashError Bad arguments for option \'--bam_genome_rsem=*\': \'$VIASH_PAR_BAM_GENOME_RSEM\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_BAM_GENOME_RSEM=$(ViashRemoveFlags "$1")
shift 1
;;
--bam_transcript_rsem)
[ -n "$VIASH_PAR_BAM_TRANSCRIPT_RSEM" ] && ViashError Bad arguments for option \'--bam_transcript_rsem\': \'$VIASH_PAR_BAM_TRANSCRIPT_RSEM\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_BAM_TRANSCRIPT_RSEM="$2"
[ $# -lt 2 ] && ViashError Not enough arguments passed to --bam_transcript_rsem. Use "--help" to get more information on the parameters. && exit 1
shift 2
;;
--bam_transcript_rsem=*)
[ -n "$VIASH_PAR_BAM_TRANSCRIPT_RSEM" ] && ViashError Bad arguments for option \'--bam_transcript_rsem=*\': \'$VIASH_PAR_BAM_TRANSCRIPT_RSEM\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_BAM_TRANSCRIPT_RSEM=$(ViashRemoveFlags "$1")
shift 1
;;
---engine)
VIASH_ENGINE_ID="$2"
shift 2
@@ -853,12 +974,6 @@ if [ -z "$VIASH_META_CPUS" ]; then
fi
# storing leftover values in positionals
if [[ $# -gt 0 ]]; then
VIASH_PAR_EXTRA_RSEM_CALCULATE_EXPRESSION_ARGS="$1"
shift 1
fi
# check whether required parameters exist
if [ -z ${VIASH_PAR_ID+x} ]; then
ViashError '--id' is a required argument. Use "--help" to get more information on the parameters.
@@ -922,7 +1037,7 @@ if [ -z ${VIASH_PAR_ALIGNER+x} ]; then
VIASH_PAR_ALIGNER="star_salmon"
fi
if [ -z ${VIASH_PAR_STAR_MULTIQC+x} ]; then
VIASH_PAR_STAR_MULTIQC="\$id.star_align.log"
VIASH_PAR_STAR_MULTIQC="\$id_star.log"
fi
if [ -z ${VIASH_PAR_GENOME_BAM_SORTED+x} ]; then
VIASH_PAR_GENOME_BAM_SORTED="\$id.genome.bam"
@@ -960,6 +1075,24 @@ fi
if [ -z ${VIASH_PAR_QUANT_RESULTS_FILE+x} ]; then
VIASH_PAR_QUANT_RESULTS_FILE="\$id.quant.sf"
fi
if [ -z ${VIASH_PAR_RSEM_COUNTS_GENE+x} ]; then
VIASH_PAR_RSEM_COUNTS_GENE="\$id.genes.results"
fi
if [ -z ${VIASH_PAR_COUNTS_TRANSCRIPTS+x} ]; then
VIASH_PAR_COUNTS_TRANSCRIPTS="\$id.isoforms.results"
fi
if [ -z ${VIASH_PAR_RSEM_MULTIQC+x} ]; then
VIASH_PAR_RSEM_MULTIQC="\$id.stat"
fi
if [ -z ${VIASH_PAR_BAM_STAR_RSEM+x} ]; then
VIASH_PAR_BAM_STAR_RSEM="\$id.STAR.genome.bam"
fi
if [ -z ${VIASH_PAR_BAM_GENOME_RSEM+x} ]; then
VIASH_PAR_BAM_GENOME_RSEM="\$id.genome.bam"
fi
if [ -z ${VIASH_PAR_BAM_TRANSCRIPT_RSEM+x} ]; then
VIASH_PAR_BAM_TRANSCRIPT_RSEM="\$id.transcript.bam"
fi
# check whether required files exist
if [ ! -z "$VIASH_PAR_FASTQ_1" ] && [ ! -e "$VIASH_PAR_FASTQ_1" ]; then
@@ -1154,6 +1287,27 @@ fi
if [ ! -z "$VIASH_PAR_QUANT_RESULTS_FILE" ] && [ ! -d "$(dirname "$VIASH_PAR_QUANT_RESULTS_FILE")" ]; then
mkdir -p "$(dirname "$VIASH_PAR_QUANT_RESULTS_FILE")"
fi
if [ ! -z "$VIASH_PAR_SALMON_MULTIQC" ] && [ ! -d "$(dirname "$VIASH_PAR_SALMON_MULTIQC")" ]; then
mkdir -p "$(dirname "$VIASH_PAR_SALMON_MULTIQC")"
fi
if [ ! -z "$VIASH_PAR_RSEM_COUNTS_GENE" ] && [ ! -d "$(dirname "$VIASH_PAR_RSEM_COUNTS_GENE")" ]; then
mkdir -p "$(dirname "$VIASH_PAR_RSEM_COUNTS_GENE")"
fi
if [ ! -z "$VIASH_PAR_COUNTS_TRANSCRIPTS" ] && [ ! -d "$(dirname "$VIASH_PAR_COUNTS_TRANSCRIPTS")" ]; then
mkdir -p "$(dirname "$VIASH_PAR_COUNTS_TRANSCRIPTS")"
fi
if [ ! -z "$VIASH_PAR_RSEM_MULTIQC" ] && [ ! -d "$(dirname "$VIASH_PAR_RSEM_MULTIQC")" ]; then
mkdir -p "$(dirname "$VIASH_PAR_RSEM_MULTIQC")"
fi
if [ ! -z "$VIASH_PAR_BAM_STAR_RSEM" ] && [ ! -d "$(dirname "$VIASH_PAR_BAM_STAR_RSEM")" ]; then
mkdir -p "$(dirname "$VIASH_PAR_BAM_STAR_RSEM")"
fi
if [ ! -z "$VIASH_PAR_BAM_GENOME_RSEM" ] && [ ! -d "$(dirname "$VIASH_PAR_BAM_GENOME_RSEM")" ]; then
mkdir -p "$(dirname "$VIASH_PAR_BAM_GENOME_RSEM")"
fi
if [ ! -z "$VIASH_PAR_BAM_TRANSCRIPT_RSEM" ] && [ ! -d "$(dirname "$VIASH_PAR_BAM_TRANSCRIPT_RSEM")" ]; then
mkdir -p "$(dirname "$VIASH_PAR_BAM_TRANSCRIPT_RSEM")"
fi
if [ "$VIASH_ENGINE_ID" == "native" ] ; then
if [ "$VIASH_MODE" == "run" ]; then
@@ -1477,6 +1631,11 @@ workflow run_wf {
]
)
| map { id, state ->
def mod_state = (state.aligner == 'star_salmon') ? state + [salmon_multiqc: state.quant_out_dir] : state
[ id, mod_state ]
}
| rsem_calculate_expression.run (
runIf: { id, state -> state.aligner == 'star_rsem' },
fromState: [
@@ -1497,7 +1656,7 @@ workflow run_wf {
"bam_transcript_rsem": "bam_transcript"
]
)
// RSEM_Star BAM
| samtools_sort.run (
runIf: { id, state -> state.aligner == 'star_rsem' },
@@ -1554,6 +1713,7 @@ workflow run_wf {
[ "star_alignment": "star_alignment",
"star_multiqc": "star_multiqc",
"rsem_multiqc": "rsem_multiqc",
"salmon_multiqc": "salmon_multiqc",
"genome_bam_sorted": "genome_bam_sorted",
"genome_bam_index": "genome_bam_index",
"genome_bam_stats": "genome_bam_stats",
@@ -1565,7 +1725,11 @@ workflow run_wf {
"transcriptome_bam_flagstat": "transcriptome_bam_flagstat",
"transcriptome_bam_idxstats": "transcriptome_bam_idxstats",
"quant_out_dir": "quant_out_dir",
"quant_results_file": "quant_results_file" ]
"quant_results_file": "quant_results_file",
"rsem_counts_gene": "rsem_counts_gene",
"rsem_counts_transcripts": "rsem_counts_transcripts",
"bam_genome_rsem": "bam_genome_rsem",
"bam_transcript_rsem": "bam_transcript_rsem" ]
)
emit:
@@ -1631,6 +1795,34 @@ if [ ! -z "$VIASH_PAR_QUANT_RESULTS_FILE" ] && [ ! -e "$VIASH_PAR_QUANT_RESULTS_
ViashError "Output file '$VIASH_PAR_QUANT_RESULTS_FILE' does not exist."
exit 1
fi
if [ ! -z "$VIASH_PAR_SALMON_MULTIQC" ] && [ ! -e "$VIASH_PAR_SALMON_MULTIQC" ]; then
ViashError "Output file '$VIASH_PAR_SALMON_MULTIQC' does not exist."
exit 1
fi
if [ ! -z "$VIASH_PAR_RSEM_COUNTS_GENE" ] && [ ! -e "$VIASH_PAR_RSEM_COUNTS_GENE" ]; then
ViashError "Output file '$VIASH_PAR_RSEM_COUNTS_GENE' does not exist."
exit 1
fi
if [ ! -z "$VIASH_PAR_COUNTS_TRANSCRIPTS" ] && [ ! -e "$VIASH_PAR_COUNTS_TRANSCRIPTS" ]; then
ViashError "Output file '$VIASH_PAR_COUNTS_TRANSCRIPTS' does not exist."
exit 1
fi
if [ ! -z "$VIASH_PAR_RSEM_MULTIQC" ] && [ ! -e "$VIASH_PAR_RSEM_MULTIQC" ]; then
ViashError "Output file '$VIASH_PAR_RSEM_MULTIQC' does not exist."
exit 1
fi
if [ ! -z "$VIASH_PAR_BAM_STAR_RSEM" ] && [ ! -e "$VIASH_PAR_BAM_STAR_RSEM" ]; then
ViashError "Output file '$VIASH_PAR_BAM_STAR_RSEM' does not exist."
exit 1
fi
if [ ! -z "$VIASH_PAR_BAM_GENOME_RSEM" ] && [ ! -e "$VIASH_PAR_BAM_GENOME_RSEM" ]; then
ViashError "Output file '$VIASH_PAR_BAM_GENOME_RSEM' does not exist."
exit 1
fi
if [ ! -z "$VIASH_PAR_BAM_TRANSCRIPT_RSEM" ] && [ ! -e "$VIASH_PAR_BAM_TRANSCRIPT_RSEM" ]; then
ViashError "Output file '$VIASH_PAR_BAM_TRANSCRIPT_RSEM' does not exist."
exit 1
fi
exit 0

View File

@@ -278,8 +278,8 @@ build_info:
output: "target/executable/workflows/merge_quant_results"
executable: "target/executable/workflows/merge_quant_results/merge_quant_results"
viash_version: "0.9.0"
git_commit: "64aad6a006818388eceffe024b1701b3eae06bee"
git_remote: "https://x-access-token:ghs_sq8cBpPtIm1wZvLlQUshbKRwwqLLDl0UmbNu@github.com/viash-hub/rnaseq"
git_commit: "1d87dc7c24f540c96460e69322f06d4be0bb7be8"
git_remote: "https://x-access-token:ghs_vs3fpTo1mWGISEIj2mqOUQA3IRBYZ30EQLHG@github.com/viash-hub/rnaseq"
dependencies:
- "target/nextflow/tx2gene"
- "target/nextflow/tximport"

View File

@@ -199,7 +199,7 @@ argument_groups:
name: "--processed_genome_bam"
info: null
default:
- "$id.markdup.sorted.bam"
- "$id.genome.bam"
must_exist: true
create_parent: true
required: false
@@ -210,7 +210,7 @@ argument_groups:
name: "--genome_bam_index"
info: null
default:
- "$id.markdup.sorted.bam"
- "$id.genome.bam.bai"
must_exist: true
create_parent: true
required: false
@@ -221,7 +221,7 @@ argument_groups:
name: "--genome_bam_stats"
info: null
default:
- "$id.markdup.sorted.bam.stats"
- "$id.genome.stats"
must_exist: true
create_parent: true
required: false
@@ -232,7 +232,7 @@ argument_groups:
name: "--genome_bam_flagstat"
info: null
default:
- "$id.markdup.sorted.bam.flagstat"
- "$id.genome.flagstat"
must_exist: true
create_parent: true
required: false
@@ -243,7 +243,7 @@ argument_groups:
name: "--genome_bam_idxstats"
info: null
default:
- "$id.markdup.sorted.bam.idxstats"
- "$id.genome.idxstats"
must_exist: true
create_parent: true
required: false
@@ -254,7 +254,7 @@ argument_groups:
name: "--markduplicates_metrics"
info: null
default:
- "$id.markdup.sorted.MarkDuplicates.metrics.txt"
- "$id.MarkDuplicates.metrics.txt"
must_exist: true
create_parent: true
required: false
@@ -486,8 +486,8 @@ build_info:
output: "target/executable/workflows/post_processing"
executable: "target/executable/workflows/post_processing/post_processing"
viash_version: "0.9.0"
git_commit: "64aad6a006818388eceffe024b1701b3eae06bee"
git_remote: "https://x-access-token:ghs_sq8cBpPtIm1wZvLlQUshbKRwwqLLDl0UmbNu@github.com/viash-hub/rnaseq"
git_commit: "1d87dc7c24f540c96460e69322f06d4be0bb7be8"
git_remote: "https://x-access-token:ghs_vs3fpTo1mWGISEIj2mqOUQA3IRBYZ30EQLHG@github.com/viash-hub/rnaseq"
dependencies:
- "target/nextflow/picard_markduplicates"
- "target/dependencies/vsh/vsh/biobox/v0.2.0/nextflow/samtools/samtools_sort"

View File

@@ -269,27 +269,27 @@ function ViashHelp {
echo "Output:"
echo " --processed_genome_bam"
echo " type: file, output, file must exist"
echo " default: \$id.markdup.sorted.bam"
echo " default: \$id.genome.bam"
echo ""
echo " --genome_bam_index"
echo " type: file, output, file must exist"
echo " default: \$id.markdup.sorted.bam"
echo " default: \$id.genome.bam.bai"
echo ""
echo " --genome_bam_stats"
echo " type: file, output, file must exist"
echo " default: \$id.markdup.sorted.bam.stats"
echo " default: \$id.genome.stats"
echo ""
echo " --genome_bam_flagstat"
echo " type: file, output, file must exist"
echo " default: \$id.markdup.sorted.bam.flagstat"
echo " default: \$id.genome.flagstat"
echo ""
echo " --genome_bam_idxstats"
echo " type: file, output, file must exist"
echo " default: \$id.markdup.sorted.bam.idxstats"
echo " default: \$id.genome.idxstats"
echo ""
echo " --markduplicates_metrics"
echo " type: file, output, file must exist"
echo " default: \$id.markdup.sorted.MarkDuplicates.metrics.txt"
echo " default: \$id.MarkDuplicates.metrics.txt"
echo ""
echo " --stringtie_transcript_gtf"
echo " type: file, output, file must exist"
@@ -887,22 +887,22 @@ if [ -z ${VIASH_PAR_WITH_UMI+x} ]; then
VIASH_PAR_WITH_UMI="false"
fi
if [ -z ${VIASH_PAR_PROCESSED_GENOME_BAM+x} ]; then
VIASH_PAR_PROCESSED_GENOME_BAM="\$id.markdup.sorted.bam"
VIASH_PAR_PROCESSED_GENOME_BAM="\$id.genome.bam"
fi
if [ -z ${VIASH_PAR_GENOME_BAM_INDEX+x} ]; then
VIASH_PAR_GENOME_BAM_INDEX="\$id.markdup.sorted.bam"
VIASH_PAR_GENOME_BAM_INDEX="\$id.genome.bam.bai"
fi
if [ -z ${VIASH_PAR_GENOME_BAM_STATS+x} ]; then
VIASH_PAR_GENOME_BAM_STATS="\$id.markdup.sorted.bam.stats"
VIASH_PAR_GENOME_BAM_STATS="\$id.genome.stats"
fi
if [ -z ${VIASH_PAR_GENOME_BAM_FLAGSTAT+x} ]; then
VIASH_PAR_GENOME_BAM_FLAGSTAT="\$id.markdup.sorted.bam.flagstat"
VIASH_PAR_GENOME_BAM_FLAGSTAT="\$id.genome.flagstat"
fi
if [ -z ${VIASH_PAR_GENOME_BAM_IDXSTATS+x} ]; then
VIASH_PAR_GENOME_BAM_IDXSTATS="\$id.markdup.sorted.bam.idxstats"
VIASH_PAR_GENOME_BAM_IDXSTATS="\$id.genome.idxstats"
fi
if [ -z ${VIASH_PAR_MARKDUPLICATES_METRICS+x} ]; then
VIASH_PAR_MARKDUPLICATES_METRICS="\$id.markdup.sorted.MarkDuplicates.metrics.txt"
VIASH_PAR_MARKDUPLICATES_METRICS="\$id.MarkDuplicates.metrics.txt"
fi
if [ -z ${VIASH_PAR_STRINGTIE_TRANSCRIPT_GTF+x} ]; then
VIASH_PAR_STRINGTIE_TRANSCRIPT_GTF="\$id.stringtie.transcripts.gtf"
@@ -1185,20 +1185,20 @@ workflow run_wf {
"extra_picard_args": "extra_picard_args"
],
toState: [
"genome_bam": "output_bam",
"processed_genome_bam": "output_bam",
"markduplicates_metrics": "metrics"
]
)
| samtools_sort.run (
runIf: { id, state -> !state.skip_markduplicates && !state.with_umi },
fromState: [ "input": "genome_bam" ],
toState: [ "genome_bam": "output" ],
fromState: [ "input": "processed_genome_bam" ],
toState: [ "processed_genome_bam": "output" ],
key: "genome_sorted_MarkDuplicates"
)
| samtools_index.run (
runIf: { id, state -> !state.skip_markduplicates && !state.with_umi },
fromState: [
"input": "genome_bam",
"input": "processed_genome_bam",
"csi": "bam_csi_index"
],
toState: [ "genome_bam_index": "output" ],
@@ -1207,7 +1207,7 @@ workflow run_wf {
| samtools_stats.run (
runIf: { id, state -> !state.skip_markduplicates && !state.with_umi },
fromState: [
"input": "genome_bam",
"input": "processed_genome_bam",
"bai": "genome_bam_index"
],
toState: [ "genome_bam_stats": "output" ],
@@ -1216,7 +1216,7 @@ workflow run_wf {
| samtools_flagstat.run (
runIf: { id, state -> !state.skip_markduplicates && !state.with_umi },
fromState: [
"bam": "genome_bam",
"bam": "processed_genome_bam",
"bai": "genome_bam_index"
],
toState: [ "genome_bam_flagstat": "output" ],
@@ -1225,7 +1225,7 @@ workflow run_wf {
| samtools_idxstats.run(
runIf: { id, state -> !state.skip_markduplicates && !state.with_umi },
fromState: [
"bam": "genome_bam",
"bam": "processed_genome_bam",
"bai": "genome_bam_index"
],
toState: [ "genome_bam_idxstats": "output" ],
@@ -1236,7 +1236,7 @@ workflow run_wf {
runIf: { id, state -> !state.skip_stringtie },
fromState: [
"strandedness": "strandedness",
"bam": "genome_bam",
"bam": "processed_genome_bam",
"annotation_gtf": "gtf",
"extra_stringtie_args": "extra_stringtie_args"
],
@@ -1254,7 +1254,7 @@ workflow run_wf {
runIf: { id, state -> !state.skip_bigwig },
fromState: [
"strandedness": "strandedness",
"bam": "genome_bam",
"bam": "processed_genome_bam",
"extra_bedtools_args": "extra_bedtools_args"
],
toState: [
@@ -1309,7 +1309,7 @@ workflow run_wf {
}
| setState (
"processed_genome_bam": "genome_bam",
"processed_genome_bam": "processed_genome_bam",
"genome_bam_index": "genome_bam_index",
"genome_bam_stats": "genome_bam_stats",
"genome_bam_flagstat": "genome_bam_flagstat",

View File

@@ -323,26 +323,16 @@ argument_groups:
multiple_sep: ";"
- name: "Read filtering options"
arguments:
- type: "boolean"
- type: "boolean_true"
name: "--skip_bbsplit"
description: "Skip BBSplit for removal of non-reference genome reads."
info: null
default:
- true
required: false
direction: "input"
multiple: false
multiple_sep: ";"
- type: "boolean"
- type: "boolean_true"
name: "--remove_ribo_rna"
description: "Enable the removal of reads derived from ribosomal RNA using SortMeRNA."
info: null
default:
- false
required: false
direction: "input"
multiple: false
multiple_sep: ";"
- name: "Other options"
arguments:
- type: "string"
@@ -363,7 +353,7 @@ argument_groups:
description: "Path to output directory"
info: null
default:
- "$id.$key.read_1.fastq"
- "$id.read_1.fastq"
must_exist: false
create_parent: true
required: false
@@ -375,7 +365,7 @@ argument_groups:
description: "Path to output directory"
info: null
default:
- "$id.$key.read_2.fastq"
- "$id.read_2.fastq"
must_exist: false
create_parent: true
required: false
@@ -520,6 +510,40 @@ argument_groups:
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--trim_json"
description: "The fastp json format report file name"
info: null
default:
- "$id.fastp_out.json"
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--trim_html"
description: "The fastp html format report file name"
info: null
default:
- "$id.fastp_out.html"
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--merged_out"
description: "File name to store merged fastp output."
info: null
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
resources:
- type: "nextflow_script"
path: "main.nf"
@@ -538,6 +562,11 @@ dependencies:
- name: "umitools/umitools_extract"
repository:
type: "local"
- name: "umi_tools/umi_tools_extract"
repository:
type: "vsh"
repo: "vsh/biobox"
tag: "v0.2.0"
- name: "trimgalore"
repository:
type: "local"
@@ -644,11 +673,12 @@ build_info:
output: "target/executable/workflows/pre_processing"
executable: "target/executable/workflows/pre_processing/pre_processing"
viash_version: "0.9.0"
git_commit: "64aad6a006818388eceffe024b1701b3eae06bee"
git_remote: "https://x-access-token:ghs_sq8cBpPtIm1wZvLlQUshbKRwwqLLDl0UmbNu@github.com/viash-hub/rnaseq"
git_commit: "1d87dc7c24f540c96460e69322f06d4be0bb7be8"
git_remote: "https://x-access-token:ghs_vs3fpTo1mWGISEIj2mqOUQA3IRBYZ30EQLHG@github.com/viash-hub/rnaseq"
dependencies:
- "target/nextflow/fastqc"
- "target/nextflow/umitools/umitools_extract"
- "target/dependencies/vsh/vsh/biobox/v0.2.0/nextflow/umi_tools/umi_tools_extract"
- "target/nextflow/trimgalore"
- "target/nextflow/bbmap_bbsplit"
- "target/nextflow/sortmerna"

View File

@@ -333,13 +333,11 @@ function ViashHelp {
echo ""
echo "Read filtering options:"
echo " --skip_bbsplit"
echo " type: boolean"
echo " default: true"
echo " type: boolean_true"
echo " Skip BBSplit for removal of non-reference genome reads."
echo ""
echo " --remove_ribo_rna"
echo " type: boolean"
echo " default: false"
echo " type: boolean_true"
echo " Enable the removal of reads derived from ribosomal RNA using SortMeRNA."
echo ""
echo "Other options:"
@@ -352,12 +350,12 @@ function ViashHelp {
echo "Output:"
echo " --qc_output1"
echo " type: file, output"
echo " default: \$id.\$key.read_1.fastq"
echo " default: \$id.read_1.fastq"
echo " Path to output directory"
echo ""
echo " --qc_output2"
echo " type: file, output"
echo " default: \$id.\$key.read_2.fastq"
echo " default: \$id.read_2.fastq"
echo " Path to output directory"
echo ""
echo " --fastqc_html_1"
@@ -413,6 +411,20 @@ function ViashHelp {
echo " type: file, output, file must exist"
echo " default: \$id.salmon_quant_output"
echo " Results from Salmon quant"
echo ""
echo " --trim_json"
echo " type: file, output, file must exist"
echo " default: \$id.fastp_out.json"
echo " The fastp json format report file name"
echo ""
echo " --trim_html"
echo " type: file, output, file must exist"
echo " default: \$id.fastp_out.html"
echo " The fastp html format report file name"
echo ""
echo " --merged_out"
echo " type: file, output, file must exist"
echo " File name to store merged fastp output."
}
# initialise variables
@@ -754,24 +766,12 @@ while [[ $# -gt 0 ]]; do
;;
--skip_bbsplit)
[ -n "$VIASH_PAR_SKIP_BBSPLIT" ] && ViashError Bad arguments for option \'--skip_bbsplit\': \'$VIASH_PAR_SKIP_BBSPLIT\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_SKIP_BBSPLIT="$2"
[ $# -lt 2 ] && ViashError Not enough arguments passed to --skip_bbsplit. Use "--help" to get more information on the parameters. && exit 1
shift 2
;;
--skip_bbsplit=*)
[ -n "$VIASH_PAR_SKIP_BBSPLIT" ] && ViashError Bad arguments for option \'--skip_bbsplit=*\': \'$VIASH_PAR_SKIP_BBSPLIT\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_SKIP_BBSPLIT=$(ViashRemoveFlags "$1")
VIASH_PAR_SKIP_BBSPLIT=true
shift 1
;;
--remove_ribo_rna)
[ -n "$VIASH_PAR_REMOVE_RIBO_RNA" ] && ViashError Bad arguments for option \'--remove_ribo_rna\': \'$VIASH_PAR_REMOVE_RIBO_RNA\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_REMOVE_RIBO_RNA="$2"
[ $# -lt 2 ] && ViashError Not enough arguments passed to --remove_ribo_rna. Use "--help" to get more information on the parameters. && exit 1
shift 2
;;
--remove_ribo_rna=*)
[ -n "$VIASH_PAR_REMOVE_RIBO_RNA" ] && ViashError Bad arguments for option \'--remove_ribo_rna=*\': \'$VIASH_PAR_REMOVE_RIBO_RNA\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_REMOVE_RIBO_RNA=$(ViashRemoveFlags "$1")
VIASH_PAR_REMOVE_RIBO_RNA=true
shift 1
;;
--extra_fq_subsample_args)
@@ -939,6 +939,39 @@ while [[ $# -gt 0 ]]; do
VIASH_PAR_SALMON_QUANT_OUTPUT=$(ViashRemoveFlags "$1")
shift 1
;;
--trim_json)
[ -n "$VIASH_PAR_TRIM_JSON" ] && ViashError Bad arguments for option \'--trim_json\': \'$VIASH_PAR_TRIM_JSON\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_TRIM_JSON="$2"
[ $# -lt 2 ] && ViashError Not enough arguments passed to --trim_json. Use "--help" to get more information on the parameters. && exit 1
shift 2
;;
--trim_json=*)
[ -n "$VIASH_PAR_TRIM_JSON" ] && ViashError Bad arguments for option \'--trim_json=*\': \'$VIASH_PAR_TRIM_JSON\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_TRIM_JSON=$(ViashRemoveFlags "$1")
shift 1
;;
--trim_html)
[ -n "$VIASH_PAR_TRIM_HTML" ] && ViashError Bad arguments for option \'--trim_html\': \'$VIASH_PAR_TRIM_HTML\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_TRIM_HTML="$2"
[ $# -lt 2 ] && ViashError Not enough arguments passed to --trim_html. Use "--help" to get more information on the parameters. && exit 1
shift 2
;;
--trim_html=*)
[ -n "$VIASH_PAR_TRIM_HTML" ] && ViashError Bad arguments for option \'--trim_html=*\': \'$VIASH_PAR_TRIM_HTML\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_TRIM_HTML=$(ViashRemoveFlags "$1")
shift 1
;;
--merged_out)
[ -n "$VIASH_PAR_MERGED_OUT" ] && ViashError Bad arguments for option \'--merged_out\': \'$VIASH_PAR_MERGED_OUT\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_MERGED_OUT="$2"
[ $# -lt 2 ] && ViashError Not enough arguments passed to --merged_out. Use "--help" to get more information on the parameters. && exit 1
shift 2
;;
--merged_out=*)
[ -n "$VIASH_PAR_MERGED_OUT" ] && ViashError Bad arguments for option \'--merged_out=*\': \'$VIASH_PAR_MERGED_OUT\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_MERGED_OUT=$(ViashRemoveFlags "$1")
shift 1
;;
---engine)
VIASH_ENGINE_ID="$2"
shift 2
@@ -1125,7 +1158,7 @@ if [ -z ${VIASH_PAR_EXTRA_SALMON_QUANT_ARGS+x} ]; then
VIASH_PAR_EXTRA_SALMON_QUANT_ARGS=""
fi
if [ -z ${VIASH_PAR_SKIP_BBSPLIT+x} ]; then
VIASH_PAR_SKIP_BBSPLIT="true"
VIASH_PAR_SKIP_BBSPLIT="false"
fi
if [ -z ${VIASH_PAR_REMOVE_RIBO_RNA+x} ]; then
VIASH_PAR_REMOVE_RIBO_RNA="false"
@@ -1134,10 +1167,10 @@ if [ -z ${VIASH_PAR_EXTRA_FQ_SUBSAMPLE_ARGS+x} ]; then
VIASH_PAR_EXTRA_FQ_SUBSAMPLE_ARGS="--record-count 1000000 --seed 1"
fi
if [ -z ${VIASH_PAR_QC_OUTPUT1+x} ]; then
VIASH_PAR_QC_OUTPUT1="\$id.\$key.read_1.fastq"
VIASH_PAR_QC_OUTPUT1="\$id.read_1.fastq"
fi
if [ -z ${VIASH_PAR_QC_OUTPUT2+x} ]; then
VIASH_PAR_QC_OUTPUT2="\$id.\$key.read_2.fastq"
VIASH_PAR_QC_OUTPUT2="\$id.read_2.fastq"
fi
if [ -z ${VIASH_PAR_FASTQC_HTML_1+x} ]; then
VIASH_PAR_FASTQC_HTML_1="\$id.read_1.fastqc.html"
@@ -1175,6 +1208,12 @@ fi
if [ -z ${VIASH_PAR_SALMON_QUANT_OUTPUT+x} ]; then
VIASH_PAR_SALMON_QUANT_OUTPUT="\$id.salmon_quant_output"
fi
if [ -z ${VIASH_PAR_TRIM_JSON+x} ]; then
VIASH_PAR_TRIM_JSON="\$id.fastp_out.json"
fi
if [ -z ${VIASH_PAR_TRIM_HTML+x} ]; then
VIASH_PAR_TRIM_HTML="\$id.fastp_out.html"
fi
# check whether required files exist
if [ ! -z "$VIASH_PAR_FASTQ_1" ] && [ ! -e "$VIASH_PAR_FASTQ_1" ]; then
@@ -1269,13 +1308,13 @@ if [[ -n "$VIASH_PAR_SAVE_TRIMMED" ]]; then
fi
if [[ -n "$VIASH_PAR_SKIP_BBSPLIT" ]]; then
if ! [[ "$VIASH_PAR_SKIP_BBSPLIT" =~ ^(true|True|TRUE|false|False|FALSE|yes|Yes|YES|no|No|NO)$ ]]; then
ViashError '--skip_bbsplit' has to be a boolean. Use "--help" to get more information on the parameters.
ViashError '--skip_bbsplit' has to be a boolean_true. Use "--help" to get more information on the parameters.
exit 1
fi
fi
if [[ -n "$VIASH_PAR_REMOVE_RIBO_RNA" ]]; then
if ! [[ "$VIASH_PAR_REMOVE_RIBO_RNA" =~ ^(true|True|TRUE|false|False|FALSE|yes|Yes|YES|no|No|NO)$ ]]; then
ViashError '--remove_ribo_rna' has to be a boolean. Use "--help" to get more information on the parameters.
ViashError '--remove_ribo_rna' has to be a boolean_true. Use "--help" to get more information on the parameters.
exit 1
fi
fi
@@ -1444,6 +1483,15 @@ fi
if [ ! -z "$VIASH_PAR_SALMON_QUANT_OUTPUT" ] && [ ! -d "$(dirname "$VIASH_PAR_SALMON_QUANT_OUTPUT")" ]; then
mkdir -p "$(dirname "$VIASH_PAR_SALMON_QUANT_OUTPUT")"
fi
if [ ! -z "$VIASH_PAR_TRIM_JSON" ] && [ ! -d "$(dirname "$VIASH_PAR_TRIM_JSON")" ]; then
mkdir -p "$(dirname "$VIASH_PAR_TRIM_JSON")"
fi
if [ ! -z "$VIASH_PAR_TRIM_HTML" ] && [ ! -d "$(dirname "$VIASH_PAR_TRIM_HTML")" ]; then
mkdir -p "$(dirname "$VIASH_PAR_TRIM_HTML")"
fi
if [ ! -z "$VIASH_PAR_MERGED_OUT" ] && [ ! -d "$(dirname "$VIASH_PAR_MERGED_OUT")" ]; then
mkdir -p "$(dirname "$VIASH_PAR_MERGED_OUT")"
fi
if [ "$VIASH_ENGINE_ID" == "native" ] ; then
if [ "$VIASH_MODE" == "run" ]; then
@@ -1462,6 +1510,7 @@ VIASH_DEP_TRIMGALORE="$VIASH_META_RESOURCES_DIR/../../../nextflow/trimgalore/mai
VIASH_DEP_BBMAP_BBSPLIT="$VIASH_META_RESOURCES_DIR/../../../nextflow/bbmap_bbsplit/main.nf"
VIASH_DEP_SORTMERNA="$VIASH_META_RESOURCES_DIR/../../../nextflow/sortmerna/main.nf"
VIASH_DEP_FQ_SUBSAMPLE="$VIASH_META_RESOURCES_DIR/../../../nextflow/fq_subsample/main.nf"
VIASH_DEP_UMI_TOOLS_UMI_TOOLS_EXTRACT="$VIASH_TARGET_DIR/dependencies/vsh/vsh/biobox/v0.2.0/nextflow/umi_tools/umi_tools_extract/main.nf"
VIASH_DEP_FASTP="$VIASH_TARGET_DIR/dependencies/vsh/vsh/biobox/v0.2.0/nextflow/fastp/main.nf"
VIASH_DEP_SALMON_SALMON_QUANT="$VIASH_TARGET_DIR/dependencies/vsh/vsh/biobox/v0.2.0/nextflow/salmon/salmon_quant/main.nf"
@@ -1559,7 +1608,8 @@ workflow run_wf {
"trim_zip_2": "trimmed_fastqc_zip_2",
"trim_html_1": "trimmed_fastqc_html_1",
"trim_html_2": "trimmed_fastqc_html_2"
]
],
args: [gzip: true, fastqc: true]
)
// Trim reads using fastp
@@ -1575,7 +1625,7 @@ workflow run_wf {
],
toState: [
"fastq_1": "out1",
// "fastq_2": "out2",
"fastq_2": "out2",
"failed_trim": "failed_out",
"failed_trim_unpaired1": "unpaired1",
"failed_trim_unpaired2": "unpaired2",
@@ -1639,8 +1689,10 @@ workflow run_wf {
runIf: { id, state -> state.strandedness == 'auto' },
fromState: { id, state ->
def input = state.paired ? [ state.fastq_1, state.fastq_2 ] : [ state.fastq_1 ]
[ input: input,
extra_args: state.extra_fq_subsample_args ]
[
input: input,
extra_args: state.extra_fq_subsample_args
]
},
toState: [
"subsampled_fastq_1": "output_1",
@@ -1674,9 +1726,8 @@ workflow run_wf {
def mates1 = state.paired ? state.subsampled_fastq_1 : null
def mates2 = state.paired ? state.subsampled_fastq_2 : null
[ unmated_reads: unmated_reads,
mates1: state.fastq1,
mates2: state.fastq2,
targets: state.transcript_fasta,
mates1: mates1,
mates2: mates2,
gene_map: state.gtf,
index: state.salmon_index,
lib_type: state.lib_type ]
@@ -1735,6 +1786,18 @@ if [ ! -z "$VIASH_PAR_SALMON_QUANT_OUTPUT" ] && [ ! -e "$VIASH_PAR_SALMON_QUANT_
ViashError "Output file '$VIASH_PAR_SALMON_QUANT_OUTPUT' does not exist."
exit 1
fi
if [ ! -z "$VIASH_PAR_TRIM_JSON" ] && [ ! -e "$VIASH_PAR_TRIM_JSON" ]; then
ViashError "Output file '$VIASH_PAR_TRIM_JSON' does not exist."
exit 1
fi
if [ ! -z "$VIASH_PAR_TRIM_HTML" ] && [ ! -e "$VIASH_PAR_TRIM_HTML" ]; then
ViashError "Output file '$VIASH_PAR_TRIM_HTML' does not exist."
exit 1
fi
if [ ! -z "$VIASH_PAR_MERGED_OUT" ] && [ ! -e "$VIASH_PAR_MERGED_OUT" ]; then
ViashError "Output file '$VIASH_PAR_MERGED_OUT' does not exist."
exit 1
fi
exit 0

View File

@@ -496,8 +496,8 @@ build_info:
output: "target/executable/workflows/prepare_genome"
executable: "target/executable/workflows/prepare_genome/prepare_genome"
viash_version: "0.9.0"
git_commit: "64aad6a006818388eceffe024b1701b3eae06bee"
git_remote: "https://x-access-token:ghs_sq8cBpPtIm1wZvLlQUshbKRwwqLLDl0UmbNu@github.com/viash-hub/rnaseq"
git_commit: "1d87dc7c24f540c96460e69322f06d4be0bb7be8"
git_remote: "https://x-access-token:ghs_vs3fpTo1mWGISEIj2mqOUQA3IRBYZ30EQLHG@github.com/viash-hub/rnaseq"
dependencies:
- "target/nextflow/gunzip"
- "target/dependencies/vsh/vsh/biobox/v0.2.0/nextflow/gffread"

View File

@@ -1172,9 +1172,15 @@ workflow run_wf {
// gff to gtf
| gffread.run (
runIf: {id, state -> !state.gtf && state.gff},
fromState: [ "input": "annotation" ],
fromState: [
"input": "gff",
"genome": "fasta"
],
toState: [ "gtf": "outfile" ],
args: [output: "gene_annotation.gtf"]
args: [
outfile: "gene_annotation.gtf",
gtf_output: true
]
)
| gtf_filter.run(
@@ -1253,13 +1259,19 @@ workflow run_wf {
| rsem_prepare_reference.run (
runIf: {id, state -> !state.transcript_fasta},
fromState: [
"fasta": "fasta",
"reference_fasta_files": "fasta",
"gtf": "gtf"
],
toState: [ "transcript_fasta": "transcript_fasta" ],
key: "make_transcript_fasta",
args: [transcript_fasta: "transcriptome.fasta"]
toState: [ "make_transcript_fasta_output": "output" ],
key: "make_transcript_fasta",\\
args: [reference_name: "genome"]
)
| map { id, state ->
def transcript_fasta = (!state.transcript_fasta) ?
state.make_transcript_fasta_output.listFiles().find{it.name == "genome.transcripts.fa"} :
state.transcript_fasta
[ id, state + [transcript_fasta: transcript_fasta] ]
}
// chromosome size and fai index
| getchromsizes.run (
@@ -1332,11 +1344,12 @@ workflow run_wf {
| rsem_prepare_reference.run (
runIf: {id, state -> !state.rsem_index && state.aligner == 'star_rsem'},
fromState: [
"fasta": "fasta",
"reference_fasta_files": "fasta",
"gtf": "gtf"
],
toState: [ "rsem_index": "rsem" ],
toState: [ "rsem_index": "output" ],
key: "generate_rsem_index",
args: [reference_name: "genome"]
)
// TODO: Uncompress HISAT2 index or generate from scratch if required
@@ -1366,10 +1379,7 @@ workflow run_wf {
// Uncompress Kallisto index or generate from scratch if required
| untar.run (
runIf: {id, state -> state.kallisto_index},
fromState: [
"input": "kallisto_index",
"pseudo_aligner_kmer_size": "pseudo_aligner_kmer_size"
],
fromState: [ "input": "kallisto_index" ],
toState: [ "kallisto_index": "output" ],
key: "untar_kallisto_index",
args: [output: "Kallisto_index"]

View File

@@ -139,8 +139,6 @@ argument_groups:
- type: "file"
name: "--pseudo_multiqc"
info: null
default:
- "$id.quant.log"
must_exist: true
create_parent: true
required: false
@@ -151,7 +149,7 @@ argument_groups:
name: "--quant_out_dir"
info: null
default:
- "$id.salmon_quant"
- "$id.quant"
must_exist: true
create_parent: true
required: false
@@ -285,8 +283,8 @@ build_info:
output: "target/executable/workflows/pseudo_alignment_and_quant"
executable: "target/executable/workflows/pseudo_alignment_and_quant/pseudo_alignment_and_quant"
viash_version: "0.9.0"
git_commit: "64aad6a006818388eceffe024b1701b3eae06bee"
git_remote: "https://x-access-token:ghs_sq8cBpPtIm1wZvLlQUshbKRwwqLLDl0UmbNu@github.com/viash-hub/rnaseq"
git_commit: "1d87dc7c24f540c96460e69322f06d4be0bb7be8"
git_remote: "https://x-access-token:ghs_vs3fpTo1mWGISEIj2mqOUQA3IRBYZ30EQLHG@github.com/viash-hub/rnaseq"
dependencies:
- "target/dependencies/vsh/vsh/biobox/v0.2.0/nextflow/salmon/salmon_quant"
- "target/nextflow/kallisto/kallisto_quant"

View File

@@ -239,11 +239,10 @@ function ViashHelp {
echo "Output:"
echo " --pseudo_multiqc"
echo " type: file, output, file must exist"
echo " default: \$id.quant.log"
echo ""
echo " --quant_out_dir"
echo " type: file, output, file must exist"
echo " default: \$id.salmon_quant"
echo " default: \$id.quant"
echo ""
echo " --salmon_quant_results_file"
echo " type: file, output, file must exist"
@@ -608,11 +607,8 @@ fi
if [ -z ${VIASH_PAR_LIB_TYPE+x} ]; then
VIASH_PAR_LIB_TYPE=""
fi
if [ -z ${VIASH_PAR_PSEUDO_MULTIQC+x} ]; then
VIASH_PAR_PSEUDO_MULTIQC="\$id.quant.log"
fi
if [ -z ${VIASH_PAR_QUANT_OUT_DIR+x} ]; then
VIASH_PAR_QUANT_OUT_DIR="\$id.salmon_quant"
VIASH_PAR_QUANT_OUT_DIR="\$id.quant"
fi
if [ -z ${VIASH_PAR_SALMON_QUANT_RESULTS_FILE+x} ]; then
VIASH_PAR_SALMON_QUANT_RESULTS_FILE="\$id.quant.sf"
@@ -852,11 +848,16 @@ workflow run_wf {
lib_type: state.lib_type ]
},
toState: [
"quant_results_dir": "output",
"quant_out_dir": "output",
"salmon_quant_results_file": "quant_results"
]
)
| map { id, state ->
def mod_state = (state.pseudo_aligner == 'salmon') ? state + [pseudo_multiqc: state.quant_out_dir] : state
[ id, mod_state ]
}
| kallisto_quant.run (
runIf: { id, state -> state.pseudo_aligner == 'kallisto'},
fromState: [

View File

@@ -97,7 +97,7 @@ argument_groups:
multiple_sep: ";"
- type: "file"
name: "--quant_out_dir"
description: "Directory containing quantification results."
description: "Directory containing Salmon quantification results."
info: null
must_exist: true
create_parent: true
@@ -107,7 +107,7 @@ argument_groups:
multiple_sep: ";"
- type: "file"
name: "--quant_results_file"
description: "Quantification file."
description: "Salmon quantification file."
info: null
must_exist: true
create_parent: true
@@ -155,12 +155,32 @@ argument_groups:
multiple_sep: ";"
- type: "string"
name: "--pseudo_aligner"
description: "Method used for [seudo alignment and quantification."
description: "Method used for pseudo alignment and quantification."
info: null
required: false
direction: "input"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--rsem_counts_gene"
description: "Expression counts on gene level"
info: null
must_exist: true
create_parent: true
required: false
direction: "input"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--rsem_counts_transcripts"
description: "Expression counts on transcript level"
info: null
must_exist: true
create_parent: true
required: false
direction: "input"
multiple: false
multiple_sep: ";"
- type: "boolean"
name: "--skip_qc"
info: null
@@ -612,25 +632,6 @@ argument_groups:
direction: "input"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--mqc_yml"
description: "Software versions"
info: null
must_exist: true
create_parent: true
required: false
direction: "input"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--workflow_summary"
info: null
must_exist: true
create_parent: true
required: false
direction: "input"
multiple: false
multiple_sep: ";"
- type: "boolean"
name: "--passed_trimmed_reads"
info: null
@@ -731,6 +732,15 @@ argument_groups:
direction: "input"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--rsem_multiqc"
info: null
must_exist: true
create_parent: true
required: false
direction: "input"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--genome_bam_stats"
info: null
@@ -1233,15 +1243,6 @@ argument_groups:
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--multiqc_versions"
info: null
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--featurecounts"
info: null
@@ -1367,7 +1368,7 @@ argument_groups:
name: "--pseudo_tpm_gene"
info: null
default:
- "salmon.merged.pseudo_gene_tpm.tsv"
- "pseudo_gene_tpm.tsv"
must_exist: true
create_parent: true
required: false
@@ -1378,7 +1379,7 @@ argument_groups:
name: "--pseudo_counts_gene"
info: null
default:
- "salmon.merged.pseudo_gene_counts.tsv"
- "pseudo_gene_counts.tsv"
must_exist: true
create_parent: true
required: false
@@ -1389,7 +1390,7 @@ argument_groups:
name: "--pseudo_counts_gene_length_scaled"
info: null
default:
- "salmon.merged.pseudo_gene_counts_length_scaled.tsv"
- "pseudo_gene_counts_length_scaled.tsv"
must_exist: true
create_parent: true
required: false
@@ -1400,7 +1401,7 @@ argument_groups:
name: "--pseudo_counts_gene_scaled"
info: null
default:
- "salmon.merged.pseudo_gene_counts_scaled.tsv"
- "pseudo_gene_counts_scaled.tsv"
must_exist: true
create_parent: true
required: false
@@ -1411,7 +1412,7 @@ argument_groups:
name: "--pseudo_tpm_transcript"
info: null
default:
- "salmon.merged.pseudo_transcript_tpm.tsv"
- "pseudo_transcript_tpm.tsv"
must_exist: true
create_parent: true
required: false
@@ -1422,7 +1423,7 @@ argument_groups:
name: "--pseudo_counts_transcript"
info: null
default:
- "salmon.merged.pseudo_transcript_counts.tsv"
- "pseudo_transcript_counts.tsv"
must_exist: true
create_parent: true
required: false
@@ -1505,6 +1506,9 @@ dependencies:
type: "vsh"
repo: "vsh/biobox"
tag: "v0.2.0"
- name: "rsem/rsem_merge_counts"
repository:
type: "local"
- name: "workflows/merge_quant_results"
repository:
type: "local"
@@ -1592,8 +1596,8 @@ build_info:
output: "target/executable/workflows/quality_control"
executable: "target/executable/workflows/quality_control/quality_control"
viash_version: "0.9.0"
git_commit: "64aad6a006818388eceffe024b1701b3eae06bee"
git_remote: "https://x-access-token:ghs_sq8cBpPtIm1wZvLlQUshbKRwwqLLDl0UmbNu@github.com/viash-hub/rnaseq"
git_commit: "1d87dc7c24f540c96460e69322f06d4be0bb7be8"
git_remote: "https://x-access-token:ghs_vs3fpTo1mWGISEIj2mqOUQA3IRBYZ30EQLHG@github.com/viash-hub/rnaseq"
dependencies:
- "target/nextflow/rseqc/rseqc_bamstat"
- "target/nextflow/rseqc/rseqc_inferexperiment"
@@ -1611,6 +1615,7 @@ build_info:
- "target/nextflow/deseq2_qc"
- "target/nextflow/prepare_multiqc_input"
- "target/dependencies/vsh/vsh/biobox/v0.2.0/nextflow/multiqc"
- "target/nextflow/rsem/rsem_merge_counts"
- "target/nextflow/workflows/merge_quant_results"
package_config:
version: "main"

View File

@@ -222,11 +222,11 @@ function ViashHelp {
echo ""
echo " --quant_out_dir"
echo " type: file, file must exist"
echo " Directory containing quantification results."
echo " Directory containing Salmon quantification results."
echo ""
echo " --quant_results_file"
echo " type: file, file must exist"
echo " Quantification file."
echo " Salmon quantification file."
echo ""
echo " --pseudo_quant_out_dir"
echo " type: file, file must exist"
@@ -246,7 +246,15 @@ function ViashHelp {
echo ""
echo " --pseudo_aligner"
echo " type: string"
echo " Method used for [seudo alignment and quantification."
echo " Method used for pseudo alignment and quantification."
echo ""
echo " --rsem_counts_gene"
echo " type: file, file must exist"
echo " Expression counts on gene level"
echo ""
echo " --rsem_counts_transcripts"
echo " type: file, file must exist"
echo " Expression counts on transcript level"
echo ""
echo " --skip_qc"
echo " type: boolean"
@@ -483,13 +491,6 @@ function ViashHelp {
echo " --multiqc_methods_description"
echo " type: file, file must exist"
echo ""
echo " --mqc_yml"
echo " type: file, file must exist"
echo " Software versions"
echo ""
echo " --workflow_summary"
echo " type: file, file must exist"
echo ""
echo " --passed_trimmed_reads"
echo " type: boolean"
echo ""
@@ -526,6 +527,9 @@ function ViashHelp {
echo " --star_multiqc"
echo " type: file"
echo ""
echo " --rsem_multiqc"
echo " type: file, file must exist"
echo ""
echo " --genome_bam_stats"
echo " type: file"
echo ""
@@ -731,9 +735,6 @@ function ViashHelp {
echo " type: file, output, file must exist"
echo " default: multiqc_plots"
echo ""
echo " --multiqc_versions"
echo " type: file, output, file must exist"
echo ""
echo " --featurecounts"
echo " type: file, output"
echo " default: \$id.featureCounts.txt"
@@ -780,27 +781,27 @@ function ViashHelp {
echo ""
echo " --pseudo_tpm_gene"
echo " type: file, output, file must exist"
echo " default: salmon.merged.pseudo_gene_tpm.tsv"
echo " default: pseudo_gene_tpm.tsv"
echo ""
echo " --pseudo_counts_gene"
echo " type: file, output, file must exist"
echo " default: salmon.merged.pseudo_gene_counts.tsv"
echo " default: pseudo_gene_counts.tsv"
echo ""
echo " --pseudo_counts_gene_length_scaled"
echo " type: file, output, file must exist"
echo " default: salmon.merged.pseudo_gene_counts_length_scaled.tsv"
echo " default: pseudo_gene_counts_length_scaled.tsv"
echo ""
echo " --pseudo_counts_gene_scaled"
echo " type: file, output, file must exist"
echo " default: salmon.merged.pseudo_gene_counts_scaled.tsv"
echo " default: pseudo_gene_counts_scaled.tsv"
echo ""
echo " --pseudo_tpm_transcript"
echo " type: file, output, file must exist"
echo " default: salmon.merged.pseudo_transcript_tpm.tsv"
echo " default: pseudo_transcript_tpm.tsv"
echo ""
echo " --pseudo_counts_transcript"
echo " type: file, output, file must exist"
echo " default: salmon.merged.pseudo_transcript_counts.tsv"
echo " default: pseudo_transcript_counts.tsv"
echo ""
echo " --pseudo_quant_merged_summarizedexperiment"
echo " type: file, output, file must exist"
@@ -1012,6 +1013,28 @@ while [[ $# -gt 0 ]]; do
VIASH_PAR_PSEUDO_ALIGNER=$(ViashRemoveFlags "$1")
shift 1
;;
--rsem_counts_gene)
[ -n "$VIASH_PAR_RSEM_COUNTS_GENE" ] && ViashError Bad arguments for option \'--rsem_counts_gene\': \'$VIASH_PAR_RSEM_COUNTS_GENE\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_RSEM_COUNTS_GENE="$2"
[ $# -lt 2 ] && ViashError Not enough arguments passed to --rsem_counts_gene. Use "--help" to get more information on the parameters. && exit 1
shift 2
;;
--rsem_counts_gene=*)
[ -n "$VIASH_PAR_RSEM_COUNTS_GENE" ] && ViashError Bad arguments for option \'--rsem_counts_gene=*\': \'$VIASH_PAR_RSEM_COUNTS_GENE\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_RSEM_COUNTS_GENE=$(ViashRemoveFlags "$1")
shift 1
;;
--rsem_counts_transcripts)
[ -n "$VIASH_PAR_RSEM_COUNTS_TRANSCRIPTS" ] && ViashError Bad arguments for option \'--rsem_counts_transcripts\': \'$VIASH_PAR_RSEM_COUNTS_TRANSCRIPTS\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_RSEM_COUNTS_TRANSCRIPTS="$2"
[ $# -lt 2 ] && ViashError Not enough arguments passed to --rsem_counts_transcripts. Use "--help" to get more information on the parameters. && exit 1
shift 2
;;
--rsem_counts_transcripts=*)
[ -n "$VIASH_PAR_RSEM_COUNTS_TRANSCRIPTS" ] && ViashError Bad arguments for option \'--rsem_counts_transcripts=*\': \'$VIASH_PAR_RSEM_COUNTS_TRANSCRIPTS\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_RSEM_COUNTS_TRANSCRIPTS=$(ViashRemoveFlags "$1")
shift 1
;;
--skip_qc)
[ -n "$VIASH_PAR_SKIP_QC" ] && ViashError Bad arguments for option \'--skip_qc\': \'$VIASH_PAR_SKIP_QC\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_SKIP_QC="$2"
@@ -1479,28 +1502,6 @@ while [[ $# -gt 0 ]]; do
VIASH_PAR_MULTIQC_METHODS_DESCRIPTION=$(ViashRemoveFlags "$1")
shift 1
;;
--mqc_yml)
[ -n "$VIASH_PAR_MQC_YML" ] && ViashError Bad arguments for option \'--mqc_yml\': \'$VIASH_PAR_MQC_YML\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_MQC_YML="$2"
[ $# -lt 2 ] && ViashError Not enough arguments passed to --mqc_yml. Use "--help" to get more information on the parameters. && exit 1
shift 2
;;
--mqc_yml=*)
[ -n "$VIASH_PAR_MQC_YML" ] && ViashError Bad arguments for option \'--mqc_yml=*\': \'$VIASH_PAR_MQC_YML\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_MQC_YML=$(ViashRemoveFlags "$1")
shift 1
;;
--workflow_summary)
[ -n "$VIASH_PAR_WORKFLOW_SUMMARY" ] && ViashError Bad arguments for option \'--workflow_summary\': \'$VIASH_PAR_WORKFLOW_SUMMARY\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_WORKFLOW_SUMMARY="$2"
[ $# -lt 2 ] && ViashError Not enough arguments passed to --workflow_summary. Use "--help" to get more information on the parameters. && exit 1
shift 2
;;
--workflow_summary=*)
[ -n "$VIASH_PAR_WORKFLOW_SUMMARY" ] && ViashError Bad arguments for option \'--workflow_summary=*\': \'$VIASH_PAR_WORKFLOW_SUMMARY\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_WORKFLOW_SUMMARY=$(ViashRemoveFlags "$1")
shift 1
;;
--passed_trimmed_reads)
[ -n "$VIASH_PAR_PASSED_TRIMMED_READS" ] && ViashError Bad arguments for option \'--passed_trimmed_reads\': \'$VIASH_PAR_PASSED_TRIMMED_READS\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_PASSED_TRIMMED_READS="$2"
@@ -1633,6 +1634,17 @@ while [[ $# -gt 0 ]]; do
VIASH_PAR_STAR_MULTIQC=$(ViashRemoveFlags "$1")
shift 1
;;
--rsem_multiqc)
[ -n "$VIASH_PAR_RSEM_MULTIQC" ] && ViashError Bad arguments for option \'--rsem_multiqc\': \'$VIASH_PAR_RSEM_MULTIQC\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_RSEM_MULTIQC="$2"
[ $# -lt 2 ] && ViashError Not enough arguments passed to --rsem_multiqc. Use "--help" to get more information on the parameters. && exit 1
shift 2
;;
--rsem_multiqc=*)
[ -n "$VIASH_PAR_RSEM_MULTIQC" ] && ViashError Bad arguments for option \'--rsem_multiqc=*\': \'$VIASH_PAR_RSEM_MULTIQC\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_RSEM_MULTIQC=$(ViashRemoveFlags "$1")
shift 1
;;
--genome_bam_stats)
[ -n "$VIASH_PAR_GENOME_BAM_STATS" ] && ViashError Bad arguments for option \'--genome_bam_stats\': \'$VIASH_PAR_GENOME_BAM_STATS\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_GENOME_BAM_STATS="$2"
@@ -2106,17 +2118,6 @@ while [[ $# -gt 0 ]]; do
VIASH_PAR_MULTIQC_PLOTS=$(ViashRemoveFlags "$1")
shift 1
;;
--multiqc_versions)
[ -n "$VIASH_PAR_MULTIQC_VERSIONS" ] && ViashError Bad arguments for option \'--multiqc_versions\': \'$VIASH_PAR_MULTIQC_VERSIONS\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_MULTIQC_VERSIONS="$2"
[ $# -lt 2 ] && ViashError Not enough arguments passed to --multiqc_versions. Use "--help" to get more information on the parameters. && exit 1
shift 2
;;
--multiqc_versions=*)
[ -n "$VIASH_PAR_MULTIQC_VERSIONS" ] && ViashError Bad arguments for option \'--multiqc_versions=*\': \'$VIASH_PAR_MULTIQC_VERSIONS\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_MULTIQC_VERSIONS=$(ViashRemoveFlags "$1")
shift 1
;;
--featurecounts)
[ -n "$VIASH_PAR_FEATURECOUNTS" ] && ViashError Bad arguments for option \'--featurecounts\': \'$VIASH_PAR_FEATURECOUNTS\' \& \'$2\' - you should provide exactly one argument for this option. && exit 1
VIASH_PAR_FEATURECOUNTS="$2"
@@ -2704,22 +2705,22 @@ if [ -z ${VIASH_PAR_QUANT_MERGED_SUMMARIZEDEXPERIMENT+x} ]; then
VIASH_PAR_QUANT_MERGED_SUMMARIZEDEXPERIMENT="salmon_merged_summarizedexperiment"
fi
if [ -z ${VIASH_PAR_PSEUDO_TPM_GENE+x} ]; then
VIASH_PAR_PSEUDO_TPM_GENE="salmon.merged.pseudo_gene_tpm.tsv"
VIASH_PAR_PSEUDO_TPM_GENE="pseudo_gene_tpm.tsv"
fi
if [ -z ${VIASH_PAR_PSEUDO_COUNTS_GENE+x} ]; then
VIASH_PAR_PSEUDO_COUNTS_GENE="salmon.merged.pseudo_gene_counts.tsv"
VIASH_PAR_PSEUDO_COUNTS_GENE="pseudo_gene_counts.tsv"
fi
if [ -z ${VIASH_PAR_PSEUDO_COUNTS_GENE_LENGTH_SCALED+x} ]; then
VIASH_PAR_PSEUDO_COUNTS_GENE_LENGTH_SCALED="salmon.merged.pseudo_gene_counts_length_scaled.tsv"
VIASH_PAR_PSEUDO_COUNTS_GENE_LENGTH_SCALED="pseudo_gene_counts_length_scaled.tsv"
fi
if [ -z ${VIASH_PAR_PSEUDO_COUNTS_GENE_SCALED+x} ]; then
VIASH_PAR_PSEUDO_COUNTS_GENE_SCALED="salmon.merged.pseudo_gene_counts_scaled.tsv"
VIASH_PAR_PSEUDO_COUNTS_GENE_SCALED="pseudo_gene_counts_scaled.tsv"
fi
if [ -z ${VIASH_PAR_PSEUDO_TPM_TRANSCRIPT+x} ]; then
VIASH_PAR_PSEUDO_TPM_TRANSCRIPT="salmon.merged.pseudo_transcript_tpm.tsv"
VIASH_PAR_PSEUDO_TPM_TRANSCRIPT="pseudo_transcript_tpm.tsv"
fi
if [ -z ${VIASH_PAR_PSEUDO_COUNTS_TRANSCRIPT+x} ]; then
VIASH_PAR_PSEUDO_COUNTS_TRANSCRIPT="salmon.merged.pseudo_transcript_counts.tsv"
VIASH_PAR_PSEUDO_COUNTS_TRANSCRIPT="pseudo_transcript_counts.tsv"
fi
if [ -z ${VIASH_PAR_PSEUDO_QUANT_MERGED_SUMMARIZEDEXPERIMENT+x} ]; then
VIASH_PAR_PSEUDO_QUANT_MERGED_SUMMARIZEDEXPERIMENT="pseudo_quant_merged_summarizedexperiment"
@@ -2762,6 +2763,14 @@ if [ ! -z "$VIASH_PAR_PSEUDO_KALLISTO_QUANT_RESULTS_FILE" ] && [ ! -e "$VIASH_PA
ViashError "Input file '$VIASH_PAR_PSEUDO_KALLISTO_QUANT_RESULTS_FILE' does not exist."
exit 1
fi
if [ ! -z "$VIASH_PAR_RSEM_COUNTS_GENE" ] && [ ! -e "$VIASH_PAR_RSEM_COUNTS_GENE" ]; then
ViashError "Input file '$VIASH_PAR_RSEM_COUNTS_GENE' does not exist."
exit 1
fi
if [ ! -z "$VIASH_PAR_RSEM_COUNTS_TRANSCRIPTS" ] && [ ! -e "$VIASH_PAR_RSEM_COUNTS_TRANSCRIPTS" ]; then
ViashError "Input file '$VIASH_PAR_RSEM_COUNTS_TRANSCRIPTS' does not exist."
exit 1
fi
if [ ! -z "$VIASH_PAR_BIOTYPES_HEADER" ] && [ ! -e "$VIASH_PAR_BIOTYPES_HEADER" ]; then
ViashError "Input file '$VIASH_PAR_BIOTYPES_HEADER' does not exist."
exit 1
@@ -2782,12 +2791,8 @@ if [ ! -z "$VIASH_PAR_MULTIQC_METHODS_DESCRIPTION" ] && [ ! -e "$VIASH_PAR_MULTI
ViashError "Input file '$VIASH_PAR_MULTIQC_METHODS_DESCRIPTION' does not exist."
exit 1
fi
if [ ! -z "$VIASH_PAR_MQC_YML" ] && [ ! -e "$VIASH_PAR_MQC_YML" ]; then
ViashError "Input file '$VIASH_PAR_MQC_YML' does not exist."
exit 1
fi
if [ ! -z "$VIASH_PAR_WORKFLOW_SUMMARY" ] && [ ! -e "$VIASH_PAR_WORKFLOW_SUMMARY" ]; then
ViashError "Input file '$VIASH_PAR_WORKFLOW_SUMMARY' does not exist."
if [ ! -z "$VIASH_PAR_RSEM_MULTIQC" ] && [ ! -e "$VIASH_PAR_RSEM_MULTIQC" ]; then
ViashError "Input file '$VIASH_PAR_RSEM_MULTIQC' does not exist."
exit 1
fi
@@ -3259,9 +3264,6 @@ fi
if [ ! -z "$VIASH_PAR_MULTIQC_PLOTS" ] && [ ! -d "$(dirname "$VIASH_PAR_MULTIQC_PLOTS")" ]; then
mkdir -p "$(dirname "$VIASH_PAR_MULTIQC_PLOTS")"
fi
if [ ! -z "$VIASH_PAR_MULTIQC_VERSIONS" ] && [ ! -d "$(dirname "$VIASH_PAR_MULTIQC_VERSIONS")" ]; then
mkdir -p "$(dirname "$VIASH_PAR_MULTIQC_VERSIONS")"
fi
if [ ! -z "$VIASH_PAR_FEATURECOUNTS" ] && [ ! -d "$(dirname "$VIASH_PAR_FEATURECOUNTS")" ]; then
mkdir -p "$(dirname "$VIASH_PAR_FEATURECOUNTS")"
fi
@@ -3342,6 +3344,7 @@ VIASH_DEP_PRESEQ_LCEXTRAP="$VIASH_META_RESOURCES_DIR/../../../nextflow/preseq_lc
VIASH_DEP_MULTIQC_CUSTOM_BIOTYPE="$VIASH_META_RESOURCES_DIR/../../../nextflow/multiqc_custom_biotype/main.nf"
VIASH_DEP_DESEQ2_QC="$VIASH_META_RESOURCES_DIR/../../../nextflow/deseq2_qc/main.nf"
VIASH_DEP_PREPARE_MULTIQC_INPUT="$VIASH_META_RESOURCES_DIR/../../../nextflow/prepare_multiqc_input/main.nf"
VIASH_DEP_RSEM_RSEM_MERGE_COUNTS="$VIASH_META_RESOURCES_DIR/../../../nextflow/rsem/rsem_merge_counts/main.nf"
VIASH_DEP_WORKFLOWS_MERGE_QUANT_RESULTS="$VIASH_META_RESOURCES_DIR/../../../nextflow/workflows/merge_quant_results/main.nf"
VIASH_DEP_FEATURECOUNTS="$VIASH_TARGET_DIR/dependencies/vsh/vsh/biobox/v0.2.0/nextflow/featurecounts/main.nf"
VIASH_DEP_MULTIQC="$VIASH_TARGET_DIR/dependencies/vsh/vsh/biobox/v0.2.0/nextflow/multiqc/main.nf"
@@ -3421,7 +3424,7 @@ workflow run_wf {
"input": "genome_bam",
"extra_preseq_args": "extra_preseq_args"
],
toState: [ "preseq_output": "output" ],
toState: [ "preseq_output": "output" ]
)
| rseqc_bamstat.run (
@@ -3580,10 +3583,49 @@ workflow run_wf {
merged_ch = qc_ch
| toSortedList
| map { list ->
def ids = list.collect { id, state -> state.id }
def strandedness = list.collect { id, state -> state.strandedness }
def num_trimmed_reads = list.collect { id, state -> state.num_trimmed_reads }
def passed_trimmed_reads = list.collect { id, state -> state.passed_trimmed_reads }
def passed_mapping = list.collect { id, state -> state.passed_mapping }
def percent_mapped = list.collect { id, state -> state.percent_mapped }
def inferred_strand = list.collect { id, state -> state.inferred_strand }
def passed_strand_check = list.collect { id, state -> state.passed_strand_check }
def gtf = list.collect { id, state -> state.gtf }.unique()[0]
def gtf_extra_attributes = list.collect { id, state -> state.gtf_extra_attributes }.unique()[0]
def gtf_group_features = list.collect { id, state -> state.gtf_group_features }.unique()[0]
def pca_header_multiqc = list.collect { id, state -> state.pca_header_multiqc }.unique()[0]
def clustering_header_multiqc = list.collect { id, state -> state.clustering_header_multiqc }.unique()[0]
def aligner = list.collect { id, state -> state.aligner }.unique()[0]
def pseudo_aligner = list.collect { id, state -> state.pseudo_aligner }.unique()[0]
def deseq2_vst = list.collect { id, state -> state.deseq2_vst }.unique()[0]
def extra_deseq2_args = list.collect { id, state -> state.extra_deseq2_args }.unique()[0]
def extra_deseq2_args2 = list.collect { id, state -> state.extra_deseq2_args2 }.unique()[0]
def skip_deseq2_qc = list.collect { id, state -> state.skip_deseq2_qc }.unique()[0]
def skip_qc = list.collect { id, state -> state.skip_qc }.unique()[0]
def skip_align = list.collect { id, state -> state.skip_align }.unique()[0]
def skip_pseudo_align = list.collect { id, state -> state.skip_pseudo_align }.unique()[0]
def quant_results = list.collect { id, state ->
(state.quant_results_file instanceof java.nio.file.Path && state.quant_results_file.exists()) ?
state.quant_results_file :
null }
def rsem_counts_gene = list.collect { id, state ->
(state.rsem_counts_gene instanceof java.nio.file.Path && state.rsem_counts_gene.exists()) ?
state.rsem_counts_gene :
null }
def rsem_counts_transcripts = list.collect { id, state ->
(state.rsem_counts_transcripts instanceof java.nio.file.Path && state.rsem_counts_transcripts.exists()) ?
state.rsem_counts_transcripts :
null }
def pseudo_salmon_quant_results = list.collect { id, state ->
(state.pseudo_salmon_quant_results_file instanceof java.nio.file.Path && state.pseudo_salmon_quant_results_file.exists()) ?
state.pseudo_salmon_quant_results_file :
null }
def pseudo_kallisto_quant_results = list.collect { id, state ->
(state.pseudo_kallisto_quant_results_file instanceof java.nio.file.Path && state.pseudo_kallisto_quant_results_file.exists()) ?
state.pseudo_kallisto_quant_results_file :
null }
def fastqc_zip_1 = list.collect { id, state ->
(state.fastqc_zip_1 instanceof java.nio.file.Path && state.fastqc_zip_1.exists()) ?
state.fastqc_zip_1 :
@@ -3608,26 +3650,14 @@ workflow run_wf {
(state.trim_log_2 instanceof java.nio.file.Path && state.trim_log_2.exists()) ?
state.trim_log_2 :
null }
def sortmerna_log = list.collect { id, state ->
(state.sortmerna_log instanceof java.nio.file.Path && state.sortmerna_log.exists()) ?
state.sortmerna_log :
def sortmerna_multiqc = list.collect { id, state ->
(state.sortmerna_multiqc instanceof java.nio.file.Path && state.sortmerna_multiqc.exists()) ?
state.sortmerna_multiqc :
null }
def star_multiqc = list.collect { id, state ->
(state.star_multiqc instanceof java.nio.file.Path && state.star_multiqc.exists()) ?
state.star_multiqc :
null }
def quant_results = list.collect { id, state ->
(state.quant_results_file instanceof java.nio.file.Path && state.quant_results_file.exists()) ?
state.quant_results_file :
null }
def pseudo_salmon_quant_results = list.collect { id, state ->
(state.pseudo_salmon_quant_results_file instanceof java.nio.file.Path && state.pseudo_salmon_quant_results_file.exists()) ?
state.pseudo_salmon_quant_results_file :
null }
def pseudo_kallisto_quant_results = list.collect { id, state ->
(state.pseudo_kallisto_quant_results_file instanceof java.nio.file.Path && state.pseudo_kallisto_quant_results_file.exists()) ?
state.pseudo_kallisto_quant_results_file :
null }
def genome_bam_stats = list.collect { id, state ->
(state.genome_bam_stats instanceof java.nio.file.Path && state.genome_bam_stats.exists()) ?
state.genome_bam_stats :
@@ -3644,6 +3674,14 @@ workflow run_wf {
(state.markduplicates_multiqc instanceof java.nio.file.Path && state.markduplicates_multiqc.exists()) ?
state.markduplicates_multiqc :
null }
def salmon_multiqc = list.collect { id, state ->
(state.salmon_multiqc instanceof java.nio.file.Path && state.salmon_multiqc.exists()) ?
state.salmon_multiqc :
null }
def rsem_multiqc = list.collect { id, state ->
(state.rsem_multiqc instanceof java.nio.file.Path && state.rsem_multiqc.exists()) ?
state.rsem_multiqc :
null }
def pseudo_multiqc = list.collect { id, state ->
(state.pseudo_multiqc instanceof java.nio.file.Path && state.pseudo_multiqc.exists()) ?
state.pseudo_multiqc :
@@ -3704,40 +3742,45 @@ workflow run_wf {
(state.tin_output_summary instanceof java.nio.file.Path && state.tin_output_summary.exists()) ?
state.tin_output_summary :
null }
def num_trimmed_reads = list.collect { id, state -> state.num_trimmed_reads }
def passed_trimmed_reads = list.collect { id, state -> state.passed_trimmed_reads }
def passed_mapping = list.collect { id, state -> state.passed_mapping }
def percent_mapped = list.collect { id, state -> state.percent_mapped }
def inferred_strand = list.collect { id, state -> state.inferred_strand }
def passed_strand_check = list.collect { id, state -> state.passed_strand_check }
def gtf = list.collect { id, state -> state.gtf }.unique()[0]
def gtf_extra_attributes = list.collect { id, state -> state.gtf_extra_attributes }.unique()[0]
def gtf_group_features = list.collect { id, state -> state.gtf_group_features }.unique()[0]
def pca_header_multiqc = list.collect { id, state -> state.pca_header_multiqc }.unique()[0]
def clustering_header_multiqc = list.collect { id, state -> state.clustering_header_multiqc } .unique()[0]
def aligner = list.collect { id, state -> state.aligner } .unique()[0]
def pseudo_aligner = list.collect { id, state -> state.pseudo_aligner } .unique()[0]
def deseq2_vst = list.collect { id, state -> state.deseq2_vst }.unique()[0]
def extra_deseq2_args = list.collect { id, state -> state.extra_deseq2_args }.unique()[0]
def extra_deseq2_args2 = list.collect { id, state -> state.extra_deseq2_args2 }.unique()[0]
def skip_deseq2_qc = list.collect { id, state -> state.skip_deseq2_qc }.unique()[0]
def multiqc_custom_config = list.collect { id, state -> state.multiqc_custom_config }.unique()[0]
def skip_qc = list.collect { id, state -> state.skip_qc }.unique()[0]
def skip_align = list.collect { id, state -> state.skip_align }.unique()[0]
def skip_pseudo_align = list.collect { id, state -> state.skip_pseudo_align }.unique()[0]
["merged", [
ids: ids,
strandedness: strandedness,
num_trimmed_reads: num_trimmed_reads,
passed_trimmed_reads: passed_trimmed_reads,
passed_mapping: passed_mapping,
percent_mapped: percent_mapped,
inferred_strand: inferred_strand,
passed_strand_check: passed_strand_check,
skip_align: skip_align,
skip_pseudo_align: skip_pseudo_align,
quant_results: quant_results,
rsem_counts_gene: rsem_counts_gene,
rsem_counts_transcripts: rsem_counts_transcripts,
pseudo_salmon_quant_results: pseudo_salmon_quant_results,
pseudo_kallisto_quant_results: pseudo_kallisto_quant_results,
gtf: gtf,
gtf_extra_attributes: gtf_extra_attributes,
gtf_group_features: gtf_group_features,
pca_header_multiqc: pca_header_multiqc,
clustering_header_multiqc: clustering_header_multiqc,
aligner: aligner,
pseudo_aligner: pseudo_aligner,
deseq2_vst: deseq2_vst,
extra_deseq2_args: extra_deseq2_args,
extra_deseq2_args2: extra_deseq2_args2,
skip_deseq2_qc: skip_deseq2_qc,
fastqc_zip: fastqc_zip_1 + fastqc_zip_2,
trim_zip: trim_zip_1 + trim_zip_2,
trim_log: trim_log_1 + trim_log_2,
sortmerna_log: sortmerna_log,
sortmerna_multiqc: sortmerna_multiqc,
star_multiqc: star_multiqc,
salmon_multiqc: quant_results,
genome_bam_stats: genome_bam_stats,
genome_bam_flagstat: genome_bam_flagstat,
genome_bam_idxstats: genome_bam_idxstats,
markduplicates_multiqc: markduplicates_multiqc,
salmon_multiqc: salmon_multiqc,
rsem_multiqc: rsem_multiqc,
pseudo_multiqc: pseudo_multiqc,
featurecounts_multiqc: featurecounts_multiqc,
featurecounts_rrna_multiqc: featurecounts_rrna_multiqc,
@@ -3753,32 +3796,114 @@ workflow run_wf {
read_distribution_output: read_distribution_output,
read_duplication_output_duplication_rate_mapping: read_duplication_output_duplication_rate_mapping,
tin_output_summary: tin_output_summary,
quant_results: quant_results,
pseudo_salmon_quant_results: pseudo_salmon_quant_results,
pseudo_kallisto_quant_results: pseudo_kallisto_quant_results,
gtf: gtf,
gtf_extra_attributes: gtf_extra_attributes,
gtf_group_features: gtf_group_features,
pca_header_multiqc: pca_header_multiqc,
clustering_header_multiqc: clustering_header_multiqc,
aligner: aligner,
pseudo_aligner: pseudo_aligner,
deseq2_vst: deseq2_vst,
extra_deseq2_args: extra_deseq2_args,
extra_deseq2_args2: extra_deseq2_args2,
skip_deseq2_qc: skip_deseq2_qc,
num_trimmed_reads: num_trimmed_reads,
passed_trimmed_reads: passed_trimmed_reads,
passed_mapping: passed_mapping,
percent_mapped: percent_mapped,
inferred_strand: inferred_strand,
passed_strand_check: passed_strand_check,
multiqc_custom_config: multiqc_custom_config,
skip_align: skip_align,
skip_pseudo_align: skip_pseudo_align
multiqc_custom_config: multiqc_custom_config
] ]
}
// | map { list ->
// def ids = list.collect { id, state -> state.id }
// def strandedness = list.collect { id, state -> state.strandedness }
// def num_trimmed_reads = list.collect { id, state -> state.num_trimmed_reads }
// def passed_trimmed_reads = list.collect { id, state -> state.passed_trimmed_reads }
// def passed_mapping = list.collect { id, state -> state.passed_mapping }
// def percent_mapped = list.collect { id, state -> state.percent_mapped }
// def inferred_strand = list.collect { id, state -> state.inferred_strand }
// def passed_strand_check = list.collect { id, state -> state.passed_strand_check }
// def gtf = list.collect { id, state -> state.gtf }.unique()[0]
// def gtf_extra_attributes = list.collect { id, state -> state.gtf_extra_attributes }.unique()[0]
// def gtf_group_features = list.collect { id, state -> state.gtf_group_features }.unique()[0]
// def pca_header_multiqc = list.collect { id, state -> state.pca_header_multiqc }.unique()[0]
// def clustering_header_multiqc = list.collect { id, state -> state.clustering_header_multiqc }.unique()[0]
// def aligner = list.collect { id, state -> state.aligner }.unique()[0]
// def pseudo_aligner = list.collect { id, state -> state.pseudo_aligner }.unique()[0]
// def deseq2_vst = list.collect { id, state -> state.deseq2_vst }.unique()[0]
// def extra_deseq2_args = list.collect { id, state -> state.extra_deseq2_args }.unique()[0]
// def extra_deseq2_args2 = list.collect { id, state -> state.extra_deseq2_args2 }.unique()[0]
// def skip_deseq2_qc = list.collect { id, state -> state.skip_deseq2_qc }.unique()[0]
// def skip_qc = list.collect { id, state -> state.skip_qc }.unique()[0]
// def skip_align = list.collect { id, state -> state.skip_align }.unique()[0]
// def skip_pseudo_align = list.collect { id, state -> state.skip_pseudo_align }.unique()[0]
// def quant_results = list.collect { id, state ->
// (state.quant_results_file instanceof java.nio.file.Path && state.quant_results_file.exists()) ?
// state.quant_results_file :
// null }
// def rsem_counts_gene = list.collect { id, state ->
// (state.rsem_counts_gene instanceof java.nio.file.Path && state.rsem_counts_gene.exists()) ?
// state.rsem_counts_gene :
// null }
// def rsem_counts_transcripts = list.collect { id, state ->
// (state.rsem_counts_transcripts instanceof java.nio.file.Path && state.rsem_counts_transcripts.exists()) ?
// state.rsem_counts_transcripts :
// null }
// def pseudo_salmon_quant_results = list.collect { id, state ->
// (state.pseudo_salmon_quant_results_file instanceof java.nio.file.Path && state.pseudo_salmon_quant_results_file.exists()) ?
// state.pseudo_salmon_quant_results_file :
// null }
// def pseudo_kallisto_quant_results = list.collect { id, state ->
// (state.pseudo_kallisto_quant_results_file instanceof java.nio.file.Path && state.pseudo_kallisto_quant_results_file.exists()) ?
// state.pseudo_kallisto_quant_results_file :
// null }
// def fastqc_zip_1_dirs = list.collect{it[1].fastqc_zip_1.getParent()}
// def fastqc_zip_2_dirs = list.collect{it[1].fastqc_zip_2.getParent()}
// def trim_zip_1_dirs = list.collect{it[1].trim_zip_1.getParent()}
// def trim_zip_2_dirs = list.collect{it[1].trim_zip_2.getParent()}
// def trim_log_1_dirs = list.collect{it[1].trim_log_1.getParent()}
// def trim_log_2_dirs = list.collect{it[1].trim_log_2.getParent()}
// def sortmerna_multiqc_dirs = list.collect{it[1].sortmerna_multiqc.getParent()}
// def star_multiqc_dirs = list.collect{it[1].star_multiqc.getParent()}
// def genome_bam_stats_dirs = list.collect{it[1].genome_bam_stats.getParent()}
// def genome_bam_flagstat_dirs = list.collect{it[1].genome_bam_flagstat.getParent()}
// def genome_bam_idxstats_dirs = list.collect{it[1].genome_bam_idxstats}
// def markduplicates_multiqc_dirs = list.collect{it[1].markduplicates_multiqc.getParent()}
// def salmon_multiqc_dirs = list.collect{it[1].salmon_multiqc}
// def rsem_multiqc_dirs = list.collect{it[1].rsem_multiqc.getParent()}
// def pseudo_multiqc_dirs = list.collect{it[1].pseudo_multiqc.getParent()}
// def featurecounts_multiqc_dirs = list.collect{it[1].featurecounts_multiqc.getParent()}
// def featurecounts_rrna_multiqc_dirs = list.collect{it[1].featurecounts_rrna_multiqc.getParent()}
// def preseq_output_dirs = list.collect{it[1].preseq_output.getParent()}
// def qualimap_output_dirs = list.collect{it[1].qualimap_output_dir}
// def dupradar_output_dup_intercept_mqc_dirs = list.collect{it[1].dupradar_output_dup_intercept_mqc.getParent()}
// def dupradar_output_duprate_exp_denscurve_mqc_dirs = list.collect{it[1].dupradar_output_duprate_exp_denscurve_mqc.getParent()}
// def bamstat_output_dirs = list.collect{it[1].bamstat_output.getParent()}
// def strandedness_output_dirs = list.collect{it[1].strandedness_output.getParent()}
// def inner_dist_output_freq_dirs = list.collect{it[1].inner_dist_output_freq.getParent()}
// def junction_annotation_output_log_dirs = list.collect{it[1].junction_annotation_output_log.getParent()}
// def junction_saturation_output_plot_r_dirs = list.collect{it[1].junction_saturation_output_plot_r.getParent()}
// def read_distribution_output_dirs = list.collect{it[1].read_distribution_output.getParent()}
// def read_duplication_output_duplication_rate_mapping_dirs = list.collect{it[1].read_duplication_output_duplication_rate_mapping.getParent()}
// def tin_output_summary_dirs = list.collect{it[1].tin_output_summary.getParent()}
// def multiqc_custom_config_dirs = list.collect{it[1].multiqc_custom_config.getParent()}
// ["merged", [
// ids: ids,
// strandedness: strandedness,
// num_trimmed_reads: num_trimmed_reads,
// passed_trimmed_reads: passed_trimmed_reads,
// passed_mapping: passed_mapping,
// percent_mapped: percent_mapped,
// inferred_strand: inferred_strand,
// passed_strand_check: passed_strand_check,
// skip_align: skip_align,
// skip_pseudo_align: skip_pseudo_align,
// quant_results: quant_results,
// rsem_counts_gene: rsem_counts_gene,
// rsem_counts_transcripts: rsem_counts_transcripts,
// pseudo_salmon_quant_results: pseudo_salmon_quant_results,
// pseudo_kallisto_quant_results: pseudo_kallisto_quant_results,
// gtf: gtf,
// gtf_extra_attributes: gtf_extra_attributes,
// gtf_group_features: gtf_group_features,
// pca_header_multiqc: pca_header_multiqc,
// clustering_header_multiqc: clustering_header_multiqc,
// aligner: aligner,
// pseudo_aligner: pseudo_aligner,
// deseq2_vst: deseq2_vst,
// extra_deseq2_args: extra_deseq2_args,
// extra_deseq2_args2: extra_deseq2_args2,
// skip_deseq2_qc: skip_deseq2_qc,
// multiqc_input: fastqc_zip_1_dirs + fastqc_zip_2_dirs + trim_zip_1_dirs + trim_zip_2_dirs + trim_log_1_dirs + trim_log_2_dirs + sortmerna_multiqc_dirs + star_multiqc_dirs + genome_bam_stats_dirs + genome_bam_flagstat_dirs + genome_bam_idxstats_dirs + markduplicates_multiqc_dirs + salmon_multiqc_dirs + rsem_multiqc_dirs + pseudo_multiqc_dirs + featurecounts_multiqc_dirs + featurecounts_rrna_multiqc_dirs + preseq_output_dirs + qualimap_output_dirs + dupradar_output_dup_intercept_mqc_dirs + dupradar_output_duprate_exp_denscurve_mqc_dirs + bamstat_output_dirs + strandedness_output_dirs + inner_dist_output_freq_dirs + junction_annotation_output_log_dirs + junction_saturation_output_plot_r_dirs + read_distribution_output_dirs + read_duplication_output_duplication_rate_mapping_dirs + tin_output_summary_dirs + multiqc_custom_config_dirs
// ] ]
// }
// Merge quantification results of alignment
| merge_quant_results.run (
runIf: { id, state -> !state.skip_align && state.aligner == 'star_salmon' },
@@ -3800,19 +3925,36 @@ workflow run_wf {
"lengths_transcript": "lengths_transcript",
"quant_merged_summarizedexperiment": "quant_merged_summarizedexperiment"
],
key: "merge_qunat_results"
key: "merge_quant_results"
)
| rsem_merge_counts.run (
runIf: { id, state -> state.aligner == 'star_rsem' },
fromState: [
"counts_gene": "rsem_counts_gene",
"counts_transcripts": "rsem_counts_transcripts"
],
toState: [
"tpm_gene": "merged_gene_tpm",
"counts_gene": "merged_gene_counts",
"tpm_transcript": "merged_transcript_tpm",
"counts_transcript": "merged_transcript_counts"
]
)
| deseq2_qc.run (
runIf: { id, state -> !state.skip_qc && !state.skip_deseq2_qc && !state.skip_align },
fromState: [
"counts": "counts_gene_length_scaled",
"pca_header_multiqc": "pca_header_multiqc",
"clustering_header_multiqc": "clustering_header_multiqc",
"deseq2_vst": "deseq2_vst",
"extra_deseq2_args": "extra_deseq2_args",
"extra_deseq2_args2": "extra_deseq2_args2"
],
fromState: { id, state ->
def counts = (state.aligner == "star_rsem") ? state.counts_gene : state.counts_gene_length_scaled
[
counts: counts,
pca_header_multiqc: state.pca_header_multiqc,
clustering_header_multiqc: state.clustering_header_multiqc,
deseq2_vst: state.deseq2_vst,
extra_deseq2_args: state.extra_deseq2_args,
extra_deseq2_args2: state.extra_deseq2_args2
]
},
toState: [
"deseq2_output": "deseq2_output",
"deseq2_pca_multiqc": "pca_multiqc",
@@ -3913,14 +4055,15 @@ workflow run_wf {
"fastqc_raw_multiqc": "fastqc_zip",
"fastqc_trim_multiqc": "trim_zip",
"trim_log_multiqc": "trim_log",
"sortmerna_multiqc": "sortmerna_log",
"sortmerna_multiqc": "sortmerna_multiqc",
"star_multiqc": "star_multiqc",
"salmon_multiqc": "salmon_multiqc",
"rsem_multiqc": "rsem_multiqc",
"pseudo_multiqc": "pseudo_multiqc",
"samtools_stats": "genome_bam_stats",
"samtools_flagstat": "genome_bam_flagstat",
"samtools_idxstats": "genome_bam_idxstats",
"markduplicates_multiqc": "markduplicates_multiqc",
"pseudo_multiqc": "pseudo_multiqc",
"markduplicates_multiqc": "markduplicates_multiqc",
"featurecounts_multiqc": "featurecounts_multiqc",
"featurecounts_rrna_multiqc": "featurecounts_rrna_multiqc",
"aligner_pca_multiqc": "deseq2_pca_multiqc",
@@ -3949,10 +4092,11 @@ workflow run_wf {
"title": "multiqc_title",
"input": "multiqc_input",
],
args: [exclude_modules: "general_stats"],
toState: [
"multiqc_report": "output_report",
"multiqc_data": "output_data",
"multiqc_plots": "output_plots",
"multiqc_plots": "output_plots"
]
)
@@ -4054,8 +4198,7 @@ workflow run_wf {
"deseq2_output_pseudo": "deseq2_output_pseudo",
"multiqc_report": "multiqc_report",
"multiqc_data": "multiqc_data",
"multiqc_plots": "multiqc_plots",
"multiqc_versions": "multiqc_versions"
"multiqc_plots": "multiqc_plots"
]
)
@@ -4250,10 +4393,6 @@ if [ ! -z "$VIASH_PAR_MULTIQC_PLOTS" ] && [ ! -e "$VIASH_PAR_MULTIQC_PLOTS" ]; t
ViashError "Output file '$VIASH_PAR_MULTIQC_PLOTS' does not exist."
exit 1
fi
if [ ! -z "$VIASH_PAR_MULTIQC_VERSIONS" ] && [ ! -e "$VIASH_PAR_MULTIQC_VERSIONS" ]; then
ViashError "Output file '$VIASH_PAR_MULTIQC_VERSIONS' does not exist."
exit 1
fi
if [ ! -z "$VIASH_PAR_TPM_GENE" ] && [ ! -e "$VIASH_PAR_TPM_GENE" ]; then
ViashError "Output file '$VIASH_PAR_TPM_GENE' does not exist."
exit 1

View File

@@ -523,18 +523,7 @@ argument_groups:
info: null
direction: "input"
- type: "string"
name: "extra_rsem_prepare_reference_args"
description: "Extra arguments to pass to rsem-prepare-reference command in addition\
\ to defaults defined by the pipeline."
info: null
default:
- "--star"
required: false
direction: "input"
multiple: false
multiple_sep: ";"
- type: "string"
name: "extra_rsem_calculate_expression_args"
name: "--extra_rsem_calculate_expression_args"
description: "Extra arguments to pass to rsem-calculate-expression command in\
\ addition to defaults defined by the pipeline."
info: null
@@ -796,7 +785,7 @@ argument_groups:
name: "--output_fasta"
info: null
default:
- "genome/reference_genome.fasta"
- "reference/genome.fasta"
must_exist: true
create_parent: true
required: false
@@ -807,7 +796,7 @@ argument_groups:
name: "--output_gtf"
info: null
default:
- "genome/gene_annotation.gtf"
- "reference/gene_annotation.gtf"
must_exist: true
create_parent: true
required: false
@@ -818,7 +807,7 @@ argument_groups:
name: "--output_transcript_fasta"
info: null
default:
- "genome/transcriptome.fasta"
- "reference/transcriptome.fasta"
must_exist: true
create_parent: true
required: false
@@ -829,7 +818,7 @@ argument_groups:
name: "--output_gene_bed"
info: null
default:
- "genome/gene_annotation.bed"
- "reference/gene_annotation.bed"
must_exist: true
create_parent: true
required: false
@@ -841,7 +830,7 @@ argument_groups:
description: "Path to STAR index."
info: null
default:
- "genome/index/STAR"
- "reference/index/STAR"
must_exist: true
create_parent: true
required: false
@@ -853,7 +842,7 @@ argument_groups:
description: "Path to Salmon index."
info: null
default:
- "genome/index/Salmon"
- "reference/index/Salmon"
must_exist: true
create_parent: true
required: false
@@ -865,7 +854,7 @@ argument_groups:
description: "Path to BBSplit index."
info: null
default:
- "genome/index/BBSplit"
- "reference/index/BBSplit"
must_exist: true
create_parent: true
required: false
@@ -877,7 +866,7 @@ argument_groups:
description: "Path to Kallisto index."
info: null
default:
- "genome/index/Kallisto"
- "reference/index/Kallisto"
must_exist: true
create_parent: true
required: false
@@ -956,28 +945,6 @@ argument_groups:
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--trim_log_1"
info: null
default:
- "trimgalore/$id.read_1.trimming_report.txt"
must_exist: false
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--trim_log_2"
info: null
default:
- "trimgalore/$id.read_2.trimming_report.txt"
must_exist: false
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--trim_html_1"
info: null
@@ -1022,6 +989,52 @@ argument_groups:
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--trim_log_1"
info: null
default:
- "trimgalore/$id.read_1.trimming_report.txt"
must_exist: false
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--trim_log_2"
info: null
default:
- "trimgalore/$id.read_2.trimming_report.txt"
must_exist: false
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--fastp_trim_json"
description: "The fastp json format report file name"
info: null
default:
- "fastp/$id_out.json"
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--fastp_trim_html"
description: "The fastp html format report file name"
info: null
default:
- "fastp/$id_out.html"
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--sortmerna_log"
description: "Sortmerna log file."
@@ -1038,7 +1051,7 @@ argument_groups:
name: "--star_alignment"
info: null
default:
- "STAR_alignment/$id"
- "STAR/$id"
must_exist: true
create_parent: true
required: false
@@ -1049,7 +1062,7 @@ argument_groups:
name: "--genome_bam_sorted"
info: null
default:
- "STAR_alignment/genome_processed/$id.genome.bam"
- "STAR/genome_processed/$id.genome.bam"
must_exist: true
create_parent: true
required: false
@@ -1060,7 +1073,29 @@ argument_groups:
name: "--genome_bam_index"
info: null
default:
- "STAR_alignment/genome_processed/$id.genome.bam.bai"
- "STAR/genome_processed/$id.genome.bam.bai"
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--transcriptome_bam"
info: null
default:
- "STAR/transcriptome_processed/$id.transcriptome.bam"
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--transcriptome_bam_index"
info: null
default:
- "STAR/transcriptome_processed/$id.transcriptome.bam.bai"
must_exist: true
create_parent: true
required: false
@@ -1100,28 +1135,6 @@ argument_groups:
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--transcriptome_bam"
info: null
default:
- "STAR_alignment/transcriptome_processed/$id.transcriptome.bam"
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--transcriptome_bam_index"
info: null
default:
- "STAR_alignment/transcriptome_processed/$id.transcriptome.bam.bai"
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--transcriptome_bam_stats"
info: null
@@ -1159,7 +1172,89 @@ argument_groups:
name: "--salmon_quant_results"
info: null
default:
- "salmon/$id"
- "STAR_Salmon/$id"
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--salmon_quant_results_file"
info: null
default:
- "STAR_Salmon/$id/quant.sf"
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--pseudo_quant_results"
info: null
default:
- "Pseudo_align_quant/$id"
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--rsem_counts_gene"
description: "Expression counts on gene level"
info: null
default:
- "RSEM/$id.genes.results"
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--rsem_counts_transcripts"
description: "Expression counts on transcript level"
info: null
default:
- "RSEM/$id.isoforms.results"
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--bam_star_rsem"
description: "BAM file generated by STAR (from RSEM)"
info: null
default:
- "RSEM/$id.STAR.genome.bam"
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--bam_genome_rsem"
description: "Genome BAM file (from RSEM)"
info: null
default:
- "RSEM/$id.genome.bam"
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--bam_transcript_rsem"
description: "Transcript BAM file (from RSEM)"
info: null
default:
- "RSEM/$id.transcript.bam"
must_exist: true
create_parent: true
required: false
@@ -1170,7 +1265,7 @@ argument_groups:
name: "--tpm_gene"
info: null
default:
- "salmon/gene_tpm.tsv"
- "transcript_quantification/gene_tpm.tsv"
must_exist: true
create_parent: true
required: false
@@ -1181,7 +1276,7 @@ argument_groups:
name: "--counts_gene"
info: null
default:
- "salmon/gene_counts.tsv"
- "transcript_quantification/gene_counts.tsv"
must_exist: true
create_parent: true
required: false
@@ -1192,7 +1287,7 @@ argument_groups:
name: "--counts_gene_length_scaled"
info: null
default:
- "salmon/gene_counts_length_scaled.tsv"
- "transcript_quantification/gene_counts_length_scaled.tsv"
must_exist: true
create_parent: true
required: false
@@ -1203,7 +1298,7 @@ argument_groups:
name: "--counts_gene_scaled"
info: null
default:
- "salmon/gene_counts_scaled.tsv"
- "transcript_quantification/gene_counts_scaled.tsv"
must_exist: true
create_parent: true
required: false
@@ -1214,7 +1309,7 @@ argument_groups:
name: "--tpm_transcript"
info: null
default:
- "salmon/transcript_tpm.tsv"
- "transcript_quantification/transcript_tpm.tsv"
must_exist: true
create_parent: true
required: false
@@ -1225,7 +1320,7 @@ argument_groups:
name: "--counts_transcript"
info: null
default:
- "salmon/transcript_counts.tsv"
- "transcript_quantification/transcript_counts.tsv"
must_exist: true
create_parent: true
required: false
@@ -1233,10 +1328,10 @@ argument_groups:
multiple: false
multiple_sep: ";"
- type: "file"
name: "--salmon_merged_summarizedexperiment"
name: "--quant_merged_summarizedexperiment"
info: null
default:
- "salmon/summarizedexperiment"
- "transcript_quantification/summarizedexperiment"
must_exist: true
create_parent: true
required: false
@@ -1247,7 +1342,7 @@ argument_groups:
name: "--markduplicates_metrics"
info: null
default:
- "picard/$id.sorted.MarkDuplicates.metrics.txt"
- "picard/$id.MarkDuplicates.metrics.txt"
must_exist: true
create_parent: true
required: false
@@ -1840,9 +1935,66 @@ argument_groups:
multiple: false
multiple_sep: ";"
- type: "file"
name: "--versions"
name: "--pseudo_counts_gene"
info: null
must_exist: false
default:
- "pseudo_alignment_quantification/gene_counts.tsv"
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--pseudo_counts_gene_length_scaled"
info: null
default:
- "pseudo_alignment_quantification/gene_counts_length_scaled.tsv"
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--pseudo_counts_gene_scaled"
info: null
default:
- "pseudo_alignment_quantification/gene_counts_scaled.tsv"
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--pseudo_tpm_transcript"
info: null
default:
- "pseudo_alignment_quantification/transcript_tpm.tsv"
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--pseudo_counts_transcript"
info: null
default:
- "pseudo_alignment_quantification/transcript_counts.tsv"
must_exist: true
create_parent: true
required: false
direction: "output"
multiple: false
multiple_sep: ";"
- type: "file"
name: "--pseudo_quant_merged_summarizedexperiment"
info: null
default:
- "pseudo_alignment_quantification/quant_merged_summarizedexperiment"
must_exist: true
create_parent: true
required: false
direction: "output"
@@ -1965,8 +2117,8 @@ build_info:
output: "target/executable/workflows/rnaseq"
executable: "target/executable/workflows/rnaseq/rnaseq"
viash_version: "0.9.0"
git_commit: "64aad6a006818388eceffe024b1701b3eae06bee"
git_remote: "https://x-access-token:ghs_sq8cBpPtIm1wZvLlQUshbKRwwqLLDl0UmbNu@github.com/viash-hub/rnaseq"
git_commit: "1d87dc7c24f540c96460e69322f06d4be0bb7be8"
git_remote: "https://x-access-token:ghs_vs3fpTo1mWGISEIj2mqOUQA3IRBYZ30EQLHG@github.com/viash-hub/rnaseq"
dependencies:
- "target/nextflow/workflows/prepare_genome"
- "target/nextflow/cat_fastq"

File diff suppressed because it is too large Load Diff