1. Learn
  2. /
  3. Courses
  4. /
  5. Scalable Data Processing in R

Connected

Exercise

Foldable operations (I)

An operation that gives the same answer whether you apply it to an entire data set or to chunks of a data set and then on the results on the chunks is sometimes called foldable. The max() and min() operations are an example of this. Here, we have defined a foldable version of the range() function that takes either a vector or list of vectors. Verify that the function works by testing it on the mortgage data set.

Instructions

100 XP
  • Verify that foldable_range() works on the "record_number" column of the mort data set.