Basic R language coding records and collections