Chapter 7
Guide to Entering, Editing, Saving, and Retrieving Large Quantities of Data Using R
7.1 CREATING AND EDITING A DATA FILE
Let’s begin by reentering the class data from Chapter 1:
height = c(141, 156.5, 162, 159, 157, 143.5, 154, 158, 140, 142, 150, 148.5, 138.5, 161, 153, 145, 147, 158.5, 160.5, 167.5, 155, 137) armspan = c(141, 156.5, 162, 159, 158, 143.5, 155.5, 160, 140, 142.5, 148, 148.5, 139, 160, 152.5, 142, 146.5, 159.5, 160.5, 164, 157, 137.5)
and put them together into a data frame we can add new data to:
tdata=data.frame(height,armspan)
Now let’s add some data
classdata=edit(tdata)
When the edit window opens as shown in Figure 7.1, we click on the heading “var3” in column 3.
Next, we add entries to the column we’ve created as shown in Figure 7.2.
7.2 STORING AND ...
Get Introduction to Statistics Through Resampling Methods and R, 2nd Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.