From 4e3398c6459b60daa62e5764879162930417a0b0 Mon Sep 17 00:00:00 2001
From: "Gervaise H. Henry" <gervaise.henry@utsouthwestern.edu>
Date: Fri, 14 Aug 2020 12:42:38 -0500
Subject: [PATCH] Only run downstreamViz on param

---
 astrocyte_pkg.yml | 11 +++++++++++
 workflow/main.nf  |  4 ++++
 2 files changed, 15 insertions(+)

diff --git a/astrocyte_pkg.yml b/astrocyte_pkg.yml
index 29f82cd..81b430f 100755
--- a/astrocyte_pkg.yml
+++ b/astrocyte_pkg.yml
@@ -159,6 +159,17 @@ workflow_parameters:
     description: |
       10x cellranger version.
 
+  - id: vizFiles
+    type: select
+    choices:
+      - [ 'true', 'Yes' ]
+      - [ 'false', 'No' ]
+    default: 'true'
+    required: true
+    description: |
+      Create objects which can be used for downstream visualization and analysis of each sample outputs. Currently created: Seurat R-objects.
+
+
   - id: astrocyte
     type: select
     choices:
diff --git a/workflow/main.nf b/workflow/main.nf
index 7af1756..1fb8fca 100755
--- a/workflow/main.nf
+++ b/workflow/main.nf
@@ -81,6 +81,7 @@ expectCells = params.expectCells
 forceCells = params.forceCells
 chemistryParam = params.chemistryParam
 version = params.version
+vizFiles = params.vizFiles
 outDir = params.outDir
 
 // Define script files
@@ -397,6 +398,9 @@ process downstreamViz {
     file "*.rds" into seuratPaths
     file "version_seurat.txt" into version_seurat
 
+  when:
+    vizFiles
+
   script:
     """
     hostname
-- 
GitLab