First try at R Programming assignment