diff --git a/project.clj b/project.clj index 907447c..3588612 100644 --- a/project.clj +++ b/project.clj @@ -1,4 +1,4 @@ -(defproject bcbio.variation "0.2.2" +(defproject bcbio.variation "0.2.3-SNAPSHOT" :description "Toolkit to analyze genomic variation data, built on the GATK with Clojure" :license {:name "MIT" :url "http://www.opensource.org/licenses/mit-license.html"} :dependencies [[org.clojure/clojure "1.5.1"] diff --git a/src/bcbio/align/ref.clj b/src/bcbio/align/ref.clj index 5801140..d397b39 100644 --- a/src/bcbio/align/ref.clj +++ b/src/bcbio/align/ref.clj @@ -76,9 +76,10 @@ (let [ref-map (get-seq-name-map ref-file) is-tab? (with-open [rdr (reader bed-file)] (.contains (first (drop-while #(.startsWith % "track") (line-seq rdr))) "\t"))] - (fn [line] + (fn [raw-line] (when-not (.startsWith line "track") - (let [parts (if is-tab? + (let [line (string/trimr raw-line) + parts (if is-tab? (string/split line #"\t") (string/split line #" "))] (let [[chr start end] (take 3 parts)]