Fix function names in examples

Some examples were using incorrect/old names for functions.
Also fixes the name for `R.sortBy` (`sortyBy` -> `sortBy`).