oilabs-tidy icon indicating copy to clipboard operation
oilabs-tidy copied to clipboard

Arbuthnot not adding to environment

Open EricFriedlander opened this issue 3 years ago • 3 comments

Hello! I'm working through Lab 1 in preparation for the spring semester. I've found that when I follow the directions in the lab and simply type arbuthnot into my console (or in a chunk) it does not add arbuthnot to my global environment. Am I doing something incorrectly? Is there an option in RStudio that I need to change?

I can add it by either typing arbuthnot <- arbuthnot or data(arbuthnot) which seems to be how it used to be coded. Any tips?

EricFriedlander avatar Jan 12 '22 17:01 EricFriedlander

Correct, this is how R will load datasets lazily. If the goal is to get students to see the data, they can also use View(arbuthnot).

mine-cetinkaya-rundel avatar Jan 14 '22 02:01 mine-cetinkaya-rundel

After the directions to just run the command arbuthnot the Lab says:

"The single line of code included in this code chunk instructs R to load some data: the Arbuthnot baptism counts for boys and girls. You should see that the Environment tab in the upper right hand corner of the RStudio window now lists a data set called arbuthnot that has 82 observations on 3 variables."

If I'm understanding your comment correctly, then this isn't true. Is that correct?

EricFriedlander avatar Jan 14 '22 04:01 EricFriedlander

@EricFriedlander You're right, we should update these instructions. We've changed how data is loaded in the package (based on CRAN recommendations) and looks like we haven't updated the instructions to match. I'll reopen the issue as a reminder to update.

mine-cetinkaya-rundel avatar Jan 17 '22 02:01 mine-cetinkaya-rundel