Skip to content
Create a gist now

Instantly share code, notes, and snippets.

(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 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.