January 2019
Beginner to intermediate
352 pages
9h 8m
English
This chapter covers
You saw in chapter 6 that you can conditionally select elements from data structures, but sometimes you only want to do (or not do) something based on some condition, or do something many times with slightly different conditions. There may be many steps you want to conditionally perform, so you need a way to only do things sometimes (or many times). You can use several approaches to do this in R, so let’s look at the most common and the most useful, as well as some other ways these tasks can be accomplished.
So far, you’ve evaluated code in a very linear ...