R programming - Data Structures