mirror of
https://github.com/MillironX/nf-core_modules.git
synced 2024-12-21 10:48:18 +00:00
Added output files to ASCAT (#1820)
* add unzip alleles + loci * fix the partial absolute prefix path * exchanged deprecated function + added metrics * updated meta * tested logRCorrection + cram input * added BED for WES * added outputs + alleleCounter version * test samtools chr operations, fixed cancerit conda * ch formatting, fasta, bed input * comment out local tests * added metrics, bed, ref_fasta * rm print statement * added stub outputs * rm versions.yml * fix linting * rm fictitious md5sums for stub-run * try fixing top-level of stub versions.yml * ordered inputs alphabetically, ref_fasta -> fasta * rm R system command, adjust meta.yml * prettier yml * added outputs + prefix to outputs * added test-yml outputs * change underscores to dots
This commit is contained in:
parent
a9521de5ac
commit
98ffb09002
2 changed files with 42 additions and 35 deletions
|
@ -17,12 +17,14 @@ process ASCAT {
|
|||
path(rt_file) // optional
|
||||
|
||||
output:
|
||||
tuple val(meta), path("*png"), emit: png
|
||||
tuple val(meta), path("*alleleFrequencies_chr*.txt"), emit: allelefreqs
|
||||
tuple val(meta), path("*BAF.txt"), emit: bafs
|
||||
tuple val(meta), path("*cnvs.txt"), emit: cnvs
|
||||
tuple val(meta), path("*LogR.txt"), emit: logrs
|
||||
tuple val(meta), path("*metrics.txt"), emit: metrics
|
||||
tuple val(meta), path("*png"), emit: png
|
||||
tuple val(meta), path("*purityploidy.txt"), emit: purityploidy
|
||||
tuple val(meta), path("*segments.txt"), emit: segments
|
||||
tuple val(meta), path("*alleleFrequencies_chr*.txt"), emit: allelefreqs
|
||||
path "versions.yml", emit: versions
|
||||
|
||||
when:
|
||||
|
@ -64,8 +66,8 @@ process ASCAT {
|
|||
ascat.prepareHTS(
|
||||
tumourseqfile = "$input_tumor",
|
||||
normalseqfile = "$input_normal",
|
||||
tumourname = "Tumour",
|
||||
normalname = "Normal",
|
||||
tumourname = paste0("$prefix", ".tumour"),
|
||||
normalname = paste0("$prefix", ".normal"),
|
||||
allelecounter_exe = "alleleCounter",
|
||||
alleles.prefix = allele_prefix,
|
||||
loci.prefix = loci_prefix,
|
||||
|
@ -85,16 +87,16 @@ process ASCAT {
|
|||
|
||||
#Load the data
|
||||
ascat.bc = ascat.loadData(
|
||||
Tumor_LogR_file = "Tumour_tumourLogR.txt",
|
||||
Tumor_BAF_file = "Tumour_normalBAF.txt",
|
||||
Germline_LogR_file = "Tumour_normalLogR.txt",
|
||||
Germline_BAF_file = "Tumour_normalBAF.txt",
|
||||
Tumor_LogR_file = paste0("$prefix", ".tumour_tumourLogR.txt"),
|
||||
Tumor_BAF_file = paste0("$prefix", ".tumour_tumourBAF.txt"),
|
||||
Germline_LogR_file = paste0("$prefix", ".tumour_normalLogR.txt"),
|
||||
Germline_BAF_file = paste0("$prefix", ".tumour_normalBAF.txt"),
|
||||
genomeVersion = "$genomeVersion",
|
||||
gender = "$gender"
|
||||
)
|
||||
|
||||
#Plot the raw data
|
||||
ascat.plotRawData(ascat.bc, img.prefix = "Before_correction_")
|
||||
ascat.plotRawData(ascat.bc, img.prefix = paste0("$prefix", ".before_correction."))
|
||||
|
||||
# optional LogRCorrection
|
||||
if("$gc_input" != "NULL") {
|
||||
|
@ -104,12 +106,12 @@ process ASCAT {
|
|||
rt_input = paste0(normalizePath("$rt_input"), "/", "$rt_input", ".txt")
|
||||
ascat.bc = ascat.correctLogR(ascat.bc, GCcontentfile = gc_input, replictimingfile = rt_input)
|
||||
#Plot raw data after correction
|
||||
ascat.plotRawData(ascat.bc, img.prefix = "After_correction_GC_")
|
||||
ascat.plotRawData(ascat.bc, img.prefix = paste0("$prefix", ".after_correction_gc_rt."))
|
||||
}
|
||||
else {
|
||||
ascat.bc = ascat.correctLogR(ascat.bc, GCcontentfile = gc_input, replictimingfile = $rt_input)
|
||||
#Plot raw data after correction
|
||||
ascat.plotRawData(ascat.bc, img.prefix = "After_correction_GC_RT_")
|
||||
ascat.plotRawData(ascat.bc, img.prefix = paste0("$prefix", ".after_correction_gc."))
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -165,26 +167,27 @@ process ASCAT {
|
|||
|
||||
"""
|
||||
|
||||
|
||||
stub:
|
||||
def prefix = task.ext.prefix ?: "${meta.id}"
|
||||
"""
|
||||
echo stub > ${prefix}.after_correction.gc_rt.test.tumour.germline.png
|
||||
echo stub > ${prefix}.after_correction.gc_rt.test.tumour.tumour.png
|
||||
echo stub > ${prefix}.before_correction.test.tumour.germline.png
|
||||
echo stub > ${prefix}.before_correction.test.tumour.tumour.png
|
||||
echo stub > ${prefix}.cnvs.txt
|
||||
echo stub > ${prefix}.metrics.txt
|
||||
echo stub > ${prefix}.normal_alleleFrequencies_chr21.txt
|
||||
echo stub > ${prefix}.normal_alleleFrequencies_chr22.txt
|
||||
echo stub > ${prefix}.purityploidy.txt
|
||||
echo stub > ${prefix}.segments.txt
|
||||
echo stub > Tumour.ASCATprofile.png
|
||||
echo stub > Tumour.ASPCF.png
|
||||
echo stub > Before_correction_Tumour.germline.png
|
||||
echo stub > After_correction_GC_Tumour.germline.png
|
||||
echo stub > Tumour.rawprofile.png
|
||||
echo stub > Tumour.sunrise.png
|
||||
echo stub > Before_correction_Tumour.tumour.png
|
||||
echo stub > After_correction_GC_Tumour.tumour.png
|
||||
echo stub > Tumour_alleleFrequencies_chr21.txt
|
||||
echo stub > Tumour_alleleFrequencies_chr22.txt
|
||||
echo stub > Normal_alleleFrequencies_chr21.txt
|
||||
echo stub > Normal_alleleFrequencies_chr22.txt
|
||||
echo stub > ${prefix}.tumour.ASPCF.png
|
||||
echo stub > ${prefix}.tumour.sunrise.png
|
||||
echo stub > ${prefix}.tumour_alleleFrequencies_chr21.txt
|
||||
echo stub > ${prefix}.tumour_alleleFrequencies_chr22.txt
|
||||
echo stub > ${prefix}.tumour_normalBAF.txt
|
||||
echo stub > ${prefix}.tumour_normalLogR.txt
|
||||
echo stub > ${prefix}.tumour_tumourBAF.txt
|
||||
echo stub > ${prefix}.tumour_tumourLogR.txt
|
||||
|
||||
echo "${task.process}:" > versions.yml
|
||||
echo ' alleleCounter: 4.3.0' >> versions.yml
|
||||
|
|
|
@ -3,17 +3,21 @@
|
|||
tags:
|
||||
- ascat
|
||||
files:
|
||||
- path: output/ascat/After_correction_GC_Tumour.germline.png
|
||||
- path: output/ascat/After_correction_GC_Tumour.tumour.png
|
||||
- path: output/ascat/Before_correction_Tumour.germline.png
|
||||
- path: output/ascat/Before_correction_Tumour.tumour.png
|
||||
- path: output/ascat/Normal_alleleFrequencies_chr21.txt
|
||||
- path: output/ascat/Normal_alleleFrequencies_chr22.txt
|
||||
- path: output/ascat/test.after_correction.gc_rt.test.tumour.germline.png
|
||||
- path: output/ascat/test.after_correction.gc_rt.test.tumour.tumour.png
|
||||
- path: output/ascat/test.before_correction.test.tumour.germline.png
|
||||
- path: output/ascat/test.before_correction.test.tumour.tumour.png
|
||||
- path: output/ascat/test.cnvs.txt
|
||||
- path: output/ascat/test.metrics.txt
|
||||
- path: output/ascat/test.normal_alleleFrequencies_chr21.txt
|
||||
- path: output/ascat/test.normal_alleleFrequencies_chr22.txt
|
||||
- path: output/ascat/test.purityploidy.txt
|
||||
- path: output/ascat/test.segments.txt
|
||||
- path: output/ascat/Tumour_alleleFrequencies_chr21.txt
|
||||
- path: output/ascat/Tumour_alleleFrequencies_chr22.txt
|
||||
- path: output/ascat/Tumour.ASCATprofile.png
|
||||
- path: output/ascat/Tumour.rawprofile.png
|
||||
- path: output/ascat/Tumour.sunrise.png
|
||||
- path: output/ascat/test.tumour.ASPCF.png
|
||||
- path: output/ascat/test.tumour.sunrise.png
|
||||
- path: output/ascat/test.tumour_alleleFrequencies_chr21.txt
|
||||
- path: output/ascat/test.tumour_alleleFrequencies_chr22.txt
|
||||
- path: output/ascat/test.tumour_normalBAF.txt
|
||||
- path: output/ascat/test.tumour_normalLogR.txt
|
||||
- path: output/ascat/test.tumour_tumourBAF.txt
|
||||
- path: output/ascat/test.tumour_tumourLogR.txt
|
||||
|
|
Loading…
Reference in a new issue