Converting between Vector Types

Some functions expect vectors of a certain type and apply type coercion to the input automatically, e.g.:

sum(TRUE + FALSE + TRUE)
## [1] 2