Here's the tricky one. What if you want to select by column name, but you want to match the column name against a regular expression (say only names containing a vowel)? The $where method only lets you select rows of data based on a query — it's a row-wise filtering operation. We want column-wise filtering on column-names.

My first attempt involved taking the dataset, turning it into a clojure map, then filtering on the map's keys, and finally turning it back into an Incanter dataset. But doing so ran into a problem in Incanter: to-dataset and to-map are not inverse functions of each other.

That is to say, there exists a file of data *filepath* that can be read into Incanter with read-dataset such that this does not work: (to-dataset (to-map (read-dataset *filepath*))). For example, if the file is a CSV spreadsheet file with missing data in some cells (not nil, not 0, just no data).