Session Ready
Exercise

Replication

Recall that replication means you need to conduct an experiment with an adequate number of subjects to achieve an acceptable statistical power. Sample size and power will be discussed in more detail later in this chapter.

Let's examine the ToothGrowth dataset to make sure they followed the principle of replication. We'll use dplyr to do some exploratory data analysis (EDA). The data has already been loaded for you.

When using dplyr functions, we can utilize the pipe operator, %>%, to chain functions together. An example using mtcars:

data(mtcars)

mtcars %>%
    count(cyl)

count() groups mtcars by cyl and then counts how many there are of each number of cylinders.

Instructions
100 XP
  • Load the dplyr package.
  • Use count() to determine how many guinea pigs were given each supplement and dose.