the effect of this function by applying it to the
-- ~UserId~ and ~Age~ columns of the first three rows of our data set.

-- #+BEGIN_EXAMPLE
-- λ> pipePreview movieStream 3 (P.map (rsubset %~ intFieldDoubler))
-- {user id :-> 2, age :-> 48, gender :-> "M", occupation :-> "technician", zip code :-> "85711"}
-- {user id :-> 4, age :-> 106, gender :-> "F", occupation :-> "other", zip code :-> "94043"}
-- {user id :-> 6, age :-> 46, gender :-> "M", occupation :-> "writer", zip code :-> "32067"}
-- #+END_EXAMPLE

-- This is a neat way of manipulating a few columns without having to
-- worry about what other columns might exist. You might want to use this
-- for normalizing the capitalization, or truncating the length of,
-- various text fields, for example.

-- ** Mostly-Uniform Data

-- /(Warning: This section veers into types that are likely of more
-- use to library authors than end users.)/

-- Suppose we don't know much about our data, but we do know that it
-- starts with an identifying column, and then some number of numeric
-- columns. We can structurally peel off the first column, perform a
-- constrained polymorphic operation on the other columns, then glue
-- the first column back on to the result.

addTwoRest :: (AllCols Num rs, AsVinyl rs)
           => Record (s :-> a ': rs) -> Record (s :-> a ': rs)
addTwoRest (h :& t) = frameCons h (aux t)
  where aux = mapMethod [pr|Num|] (\x -> x + 2)

-- #+BEGIN_EXAMPLE
-- λ> addTwoRest (select [pr|Occupation, UserId, Age|] (frameRow ms 0))
-- {occupation :-> "technician", user id :-> 3, age :-> 26}
-- #+END_EXAMPLE

-- But what if we don't want to rely entirely on ordering of our rows?
-- Here, we know there is an identifying column, ~Occupation~, and we
-- want to shuffle it around to the head of the record while mapping a
-- constrained polymorphic operation over the other columns.

addTwoOccupation 
addTwoRest :: (AllCols Num rs, AsVinyl rs)
           => Record (s :-> a ': rs) -> Record (s :-> a ': rs)
addTwoRest (h :& t) = frameCons h (aux t)
  where aux = mapMethod [pr|Num|] (\x -> x + 2)

-- #+BEGIN_EXAMPLE
-- λ> addTwoRest (select [pr|Occupation, UserId, Age|] (frameRow ms 0))
-- {occupation :-> "technician", user id :-> 3, age :-> 26}
-- #+END_EXAMPLE

-- But what if we don't want to rely entirely on ordering of our rows?
-- Here, we know there is an identifying column, ~Occupation~, and we
-- want to shuffle it around to the head of the record while mapping a
-- constrained polymorphic operation over the other columns.
addTwoRest (h :& t) = frameCons h (aux t)
  where aux = mapMethod [pr|Num|] (\x -> x + 2)

-- #+BEGIN_EXAMPLE
-- λ> addTwoRest (select [pr|Occupation, UserId, Age|] (frameRow ms 0))
-- {occupation :-> "technician", user id :-> 3, age :-> 26}
-- #+END_EXAMPLE

-- But what if we don't want to rely entirely on ordering of our rows?
-- Here, we know there is an identifying column, ~Occupation~, and we
-- want to shuffle it around to the head of the record while mapping a
-- constrained polymorphic operation over the other columns.