Skip to content

Commit

Permalink
Remove VCF identifier input to PlotSVCountsPerSample for Terra (#224)
Browse files Browse the repository at this point in the history
  • Loading branch information
epiercehoffman authored Sep 3, 2021
1 parent 4c0d89f commit ca3b62c
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,5 @@
"PlotSVCountsPerSample.N_IQR_cutoff": "6",

"PlotSVCountsPerSample.prefix": "${this.sample_set_id}",
"PlotSVCountsPerSample.vcfs" : "${[this.sites_filtered_manta_vcf, this.sites_filtered_delly_vcf, this.sites_filtered_wham_vcf, this.sites_filtered_melt_vcf, this.sites_filtered_depth_vcf]}",
"PlotSVCountsPerSample.vcf_identifiers" : "${this.algorithms_filtersites}"
"PlotSVCountsPerSample.vcfs" : "${[this.sites_filtered_manta_vcf, this.sites_filtered_delly_vcf, this.sites_filtered_wham_vcf, this.sites_filtered_melt_vcf, this.sites_filtered_depth_vcf]}"
}
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,5 @@
{{ test_batch.sites_filtered_wham_vcf | tojson }},
{{ test_batch.sites_filtered_melt_vcf | tojson }},
{{ test_batch.sites_filtered_depth_vcf | tojson }}
],
"PlotSVCountsPerSample.vcf_identifiers" : ["manta", "wham", "melt", "depth"]
]
}
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,5 @@
"PlotSVCountsPerSample.prefix": {{ test_batch.batch_name | tojson }},
"PlotSVCountsPerSample.vcfs" : [
{{ test_batch.baseline_final_vcf | tojson }}
],
"PlotSVCountsPerSample.vcf_identifiers" : ["cohort_outlier_filtered"]
]
}
1 change: 0 additions & 1 deletion wdl/FilterBatch.wdl
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,6 @@ workflow FilterBatch {
input:
prefix = batch,
vcfs = [FilterBatchSites.sites_filtered_manta_vcf, FilterBatchSites.sites_filtered_delly_vcf, FilterBatchSites.sites_filtered_wham_vcf, FilterBatchSites.sites_filtered_melt_vcf, FilterBatchSites.sites_filtered_depth_vcf],
vcf_identifiers = FilterBatchSites.algorithms_filtersites,
N_IQR_cutoff = outlier_cutoff_nIQR,
sv_pipeline_docker = sv_pipeline_docker,
runtime_attr_count_svs = runtime_attr_count_svs,
Expand Down
1 change: 0 additions & 1 deletion wdl/FilterBatchSites.wdl
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,6 @@ workflow FilterBatchSites {
File cutoffs = AdjudicateSV.cutoffs
File scores = RewriteScores.updated_scores
File RF_intermediate_files = AdjudicateSV.RF_intermediate_files
Array[String] algorithms_filtersites = algorithms
}
}

Expand Down
14 changes: 6 additions & 8 deletions wdl/PlotSVCountsPerSample.wdl
Original file line number Diff line number Diff line change
Expand Up @@ -7,22 +7,20 @@ workflow PlotSVCountsPerSample {
input {
String prefix
Array[File?] vcfs # in order of vcf_identifiers array. To skip one, use null keyword
Array[String] vcf_identifiers # VCF identifiers - could be algorithms like manta, wham, etc or pesr, depth or just cohort VCF
Int N_IQR_cutoff
String sv_pipeline_docker
RuntimeAttr? runtime_attr_count_svs
RuntimeAttr? runtime_attr_plot_svcounts
RuntimeAttr? runtime_attr_cat_outliers_preview
}
Int num_identifiers = length(vcf_identifiers)
scatter (i in range(num_identifiers)) {
if (defined(vcfs[i])) {
scatter (vcf in vcfs) {
if (defined(vcf)) {
String vcf_name = basename(select_first([vcf]), ".vcf.gz")
call CountSVsPerSamplePerType {
input:
vcf = select_first([vcfs[i]]),
prefix = "~{prefix}.~{vcf_identifiers[i]}",
vcf = select_first([vcf]),
prefix = vcf_name,
sv_pipeline_docker = sv_pipeline_docker,
runtime_attr_override = runtime_attr_count_svs
}
Expand All @@ -31,7 +29,7 @@ workflow PlotSVCountsPerSample {
input:
svcounts = CountSVsPerSamplePerType.sv_counts,
n_iqr_cutoff = N_IQR_cutoff,
prefix = "~{prefix}.~{vcf_identifiers[i]}",
prefix = vcf_name,
sv_pipeline_docker = sv_pipeline_docker,
runtime_attr_override = runtime_attr_plot_svcounts
}
Expand Down

0 comments on commit ca3b62c

Please sign in to comment.