Learn R Programming

BSDA (version 1.2.0)

Kidsmoke: Smoking habits of boys and girls ages 12 to 18

Description

Data for Exercise 4.85

Usage

Kidsmoke

Arguments

Format

A data frame/tibble with 1000 observations on two variables

gender

character vector with values female and male

smoke

a character vector with values no and yes

References

Kitchens, L. J. (2003) Basic Statistics and Data Analysis. Pacific Grove, CA: Brooks/Cole, a division of Thomson Learning.

Examples

Run this code
# NOT RUN {
T1 <- xtabs(~smoke + gender, data = Kidsmoke)
T1
prop.table(T1)
prop.table(T1, 1)
prop.table(T1, 2)

# }

Run the code above in your browser using DataLab