From 001e834a4b8e660be8797690a2b0eb418b01fbbb Mon Sep 17 00:00:00 2001 From: Justin Bedo Date: Mon, 8 Apr 2019 09:33:33 +1000 Subject: grids: add function to include assemblies with annotated VCF --- tools/gridss-variants.nix | 10 ++++++++++ tools/gridss.nix | 6 ++++++ 2 files changed, 16 insertions(+) (limited to 'tools') diff --git a/tools/gridss-variants.nix b/tools/gridss-variants.nix index b564725..4f39b1e 100644 --- a/tools/gridss-variants.nix +++ b/tools/gridss-variants.nix @@ -111,4 +111,14 @@ rec { gridss.assembly = assembly; }; }; + + annotateAndAssemble = stage rec { + name = "gridss-annotateVariants-assemble"; + buildCommand = '' + mkdir $out + ln -s ${annotate} $out/gridss.vcf + ln -s ${assembly} $out/gridss.bam + ln -s ${bionix.samtools.index indexAttrs assembly} $out/gridss.bam.bai + ''; + }; } diff --git a/tools/gridss.nix b/tools/gridss.nix index 050a628..176bd34 100644 --- a/tools/gridss.nix +++ b/tools/gridss.nix @@ -53,6 +53,9 @@ rec { */ annotateVariants = exec (attrs: input: ((callBionix ./gridss-variants.nix attrs) input).annotate); + /* As annotateVariants except include assembly in output */ + annotateAndAssemble = exec (attrs: input: ((callBionix ./gridss-variants.nix attrs) input).annotateAndAssemble); + /* Preprocess BAM files to extract SV reads and convert soft clips to split reads Type: preprocessBam :: bam -> bam */ @@ -69,4 +72,7 @@ rec { Type: [bam] -> GRIDSS result */ call = inputs: gridss.annotateVariants {} (map gridss.preprocessBam inputs); + + /* As call but include assemblies in output */ + callAndAssemble = inputs: gridss.annotateAndAssemble {} (map gridss.preprocessBam inputs); } -- cgit v1.2.3