moderndive (version 0.2.0)

mythbusters_yawn: Data from Mythbusters' study on contagiousness of yawning

Description

From a study on whether yawning is contagious https://www.imdb.com/title/tt0768479/. The data here was derived from the final proportions of yawns given in the show.

Usage

mythbusters_yawn

Arguments

Format

A data frame of 50 rows representing each of the 50 participants in the study.

subj

integer value corresponding to identifier variable of subject ID

group

string of either "seed", participant was shown a yawner, or "control", participant was not shown a yawner

yawn

string of either "yes", the participant yawned, or "no", the participant did not yawn

Examples

Run this code
# NOT RUN {
library(ggplot2)

# Plot both variables as a stacked proportional bar chart
ggplot(mythbusters_yawn, aes(x = group, fill = yawn)) +
  geom_bar(position = "fill") +
  labs(x = "", y = "Proportion", 
  title = "Proportion of yawn and not yawn for each group")
# }

Run the code above in your browser using DataLab