Created

Embed URL

HTTPS clone URL

SSH clone URL

You can clone with HTTPS or SSH.

Download Gist
View core.clj
1 2 3 4 5 6 7 8 9 10 11 12
(ns example-cascalog.core
(:require [cascalog.api :refer [?<- stdout]]
[clojure.string :refer [split-lines split]]))
 
(defn slurp-psv
"Slurp a PSV file into a vector of vectors"
[file]
(->> file slurp split-lines (mapv #(split % #"\|"))))
 
(?<- (stdout)
[?name ?age]
((slurp-psv "/home/j1n3l0/Documents/data.psv") :> ?name _ ?age))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.