Learn R Programming

EngrExpt (version 0.1-6)

vitamin: Calcium levels before and after vitamin supplement

Description

Calcium levels before and after vitamin supplement

Arguments

References

Peter R. Nelson, Marie Coffin and Karen A. F. Copeland (2003), Introductory Statistics for Engineering Experimentation, Elsevier. (Appendix A)

Examples

Run this code
str(vitamin)
summary(vitamin)
show(plt1 <- xyplot(after ~ before, vitamin, groups = treatment,
       auto.key = list(space = "right", title = "Formulation", lines = TRUE),
       aspect = "iso",
       type = c("g","p","smooth"),
       xlab  = "Calcium level before the vitamin",
       ylab = "Calcium level after the vitamin"))
tmd(plt1, aspect = 1)
densityplot(~ I(after - before), vitamin, groups = treatment,
            auto.key = list(columns = 3, lines = TRUE),
            xlab = "Change in calcium level after taking vitamin")

Run the code above in your browser using DataLab