From b3c3023c3ced88987e586918fd9c439846035995 Mon Sep 17 00:00:00 2001 From: sjia Date: Mon, 14 Jun 2010 18:56:08 +0000 Subject: [PATCH] Allows callers to handle HLA reference files as input (rather than hard-coded paths) git-svn-id: file:///humgen/gsa-scr1/gsa-engineering/svn_contents/trunk@3552 348d0f76-0448-11de-a6fe-93d51630548a --- .../HLAcaller/CalculateBaseLikelihoodsWalker.java | 11 ----------- .../gatk/walkers/HLAcaller/FindClosestHLAWalker.java | 11 ++++++++--- .../gatk/walkers/HLAcaller/HLACallerWalker.java | 10 ++++++---- 3 files changed, 14 insertions(+), 18 deletions(-) diff --git a/java/src/org/broadinstitute/sting/playground/gatk/walkers/HLAcaller/CalculateBaseLikelihoodsWalker.java b/java/src/org/broadinstitute/sting/playground/gatk/walkers/HLAcaller/CalculateBaseLikelihoodsWalker.java index 84205de97..e332e6c89 100644 --- a/java/src/org/broadinstitute/sting/playground/gatk/walkers/HLAcaller/CalculateBaseLikelihoodsWalker.java +++ b/java/src/org/broadinstitute/sting/playground/gatk/walkers/HLAcaller/CalculateBaseLikelihoodsWalker.java @@ -58,17 +58,6 @@ public class CalculateBaseLikelihoodsWalker extends LocusWalker ReadsToDiscard = new ArrayList(); diff --git a/java/src/org/broadinstitute/sting/playground/gatk/walkers/HLAcaller/FindClosestHLAWalker.java b/java/src/org/broadinstitute/sting/playground/gatk/walkers/HLAcaller/FindClosestHLAWalker.java index 199fc6ef9..2095d2c99 100644 --- a/java/src/org/broadinstitute/sting/playground/gatk/walkers/HLAcaller/FindClosestHLAWalker.java +++ b/java/src/org/broadinstitute/sting/playground/gatk/walkers/HLAcaller/FindClosestHLAWalker.java @@ -60,10 +60,15 @@ public class FindClosestHLAWalker extends ReadWalker { @Argument(fullName = "onlyfrequent", shortName = "onlyfrequent", doc = "Only consider alleles with frequency > 0.0001", required = false) public boolean ONLYFREQUENT = false; - String HLAdatabaseFile = "/humgen/gsa-scr1/GSA/sjia/HLA_CALLER/HLA_DICTIONARY.txt"; - String PolymorphicSitesFile = "/humgen/gsa-scr1/GSA/sjia/HLA_CALLER/HLA_POLYMORPHIC_SITES.txt"; - String AlleleFrequencyFile = "/humgen/gsa-scr1/GSA/sjia/HLA_CALLER/HLA_FREQUENCIES.txt"; + @Argument(fullName = "HLAfrequencies", shortName = "HLAfrequencies", doc = "HLA allele frequencies file", required = true) + public String AlleleFrequencyFile = "HLA_FREQUENCIES.txt"; + @Argument(fullName = "HLAdictionary", shortName = "HLAdictionary", doc = "HLA dictionary file", required = true) + public String HLAdatabaseFile = "HLA_DICTIONARY.txt"; + + @Argument(fullName = "PolymorphicSites", shortName = "PolymorphicSites", doc = "file containing polymorphic sites within the HLA", required = true) + public String PolymorphicSitesFile = "HLA_POLYMORPHIC_SITES.txt"; + HLAFileReader HLADictionaryReader = new HLAFileReader(); boolean DatabaseLoaded = false; diff --git a/java/src/org/broadinstitute/sting/playground/gatk/walkers/HLAcaller/HLACallerWalker.java b/java/src/org/broadinstitute/sting/playground/gatk/walkers/HLAcaller/HLACallerWalker.java index 8a98f6e17..6be125e98 100644 --- a/java/src/org/broadinstitute/sting/playground/gatk/walkers/HLAcaller/HLACallerWalker.java +++ b/java/src/org/broadinstitute/sting/playground/gatk/walkers/HLAcaller/HLACallerWalker.java @@ -69,12 +69,14 @@ public class HLACallerWalker extends ReadWalker { @Argument(fullName = "minRequiredMatches", shortName = "minRequiredMatches", doc = "Min number of matches required per read (default 7)", required = false) public int MINREQUIREDMATCHES = 5; + @Argument(fullName = "HLAfrequencies", shortName = "HLAfrequencies", doc = "HLA allele frequencies file", required = true) + public String AlleleFrequencyFile = "HLA_FREQUENCIES.txt"; + + @Argument(fullName = "HLAdictionary", shortName = "HLAdictionary", doc = "HLA dictionary file", required = true) + public String HLAdatabaseFile = "HLA_DICTIONARY.txt"; + GATKArgumentCollection args = this.getToolkit().getArguments(); - String AlleleFrequencyFile = "/humgen/gsa-scr1/GSA/sjia/HLA_CALLER/HLA_FREQUENCIES.txt"; - String PolymorphicSitesfile = "/humgen/gsa-scr1/GSA/sjia/HLA_CALLER/HLA_POLYMORPHIC_SITES.txt"; - String HLAdatabaseFile = "/humgen/gsa-scr1/GSA/sjia/HLA_CALLER/HLA_DICTIONARY.txt"; - // Initializing variables HLAFileReader HLADictionaryReader = new HLAFileReader();