ABSTRACT

This chapter presents character and complex data and then introduces non-atomic data. The values can contain numeric, logical, or character data, or they can themselves be objects. The chapter occasionally uses the term vector, rather than object, when people want to emphasize that they are talking about such simple objects. The philosophy underlying S is to organize computations in terms of whole data structures whenever possible, rather than as iterative calculations on single numbers or character strings. The elements in atomic vectors are numbers, complex numbers, logical values, or character strings. Subscripting is one of the most commonly used of all S operations, and is used to extract and/or replicate values from objects. On the left side of an assignment, it forms the essential operation to replace values of elements. The paste function is a flexible way of creating a character vector out of any combination of arguments.