Outcomes and probabilities of the roll of a pair of fair dice
Data for Exercise 3.109
Dice
A data frame/tibble with 11 observations on two variables
possible outcomes for the sum of two dice
probability for outcome x
Kitchens, L. J. (2003) Basic Statistics and Data Analysis. Pacific Grove, CA: Brooks/Cole, a division of Thomson Learning.
roll1 <- sample(1:6, 20000, replace = TRUE) roll2 <- sample(1:6, 20000, replace = TRUE) outcome <- roll1 + roll2 T1 <- table(outcome)/length(outcome) remove(roll1, roll2, outcome) T1 round(t(Dice), 5) rm(roll1, roll2, T1)
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.