R Data Structures

R also has a number of basic data structures. A data structure is either homogeneous (all elements are of the same data type) or heterogeneous (elements can be of more than one data type).

The most basic type of R object is a vector. Empty vectors can be created with the vector() function. There is really only one rule about vectors in R, which is that A vector can only contain objects of the same class.

It is Very Important to understand because these are the data types you will manipulate on a day-to-day basis in R. Each one of these things will be discussed one by one in subsequent sections. 

R Objects and Attributes