Learn R Programming

PASWR2 (version 1.0.5)

DROSOPHILA: Drosophila Melanogaster

Description

DROSOPHILA contains per diem fecundity (number of eggs laid per female per day for the first 14 days of life) for 25 females from each of three lines of Drosophila melanogaster. The three lines are Nonselected (control), Resistant, and Susceptible.

Usage

DROSOPHILA

Arguments

Format

A data frame with 75 observations on the following 2 variables:

  • fecundity (number of eggs laid per female per day for the first 14 days of life)

  • line (a factor with levels Nonselected, Resistant, and Susceptible)

References

  • Sokal, R. R. and Rohlf, F. J. 1994. Biometry. W. H. Freeman, New York, third edition.

  • Ugarte, M. D., Militino, A. F., and Arnholt, A. T. 2015. Probability and Statistics with R, Second Edition. Chapman & Hall / CRC.

Examples

Run this code
# NOT RUN {
ggplot(data = DROSOPHILA, aes(x = reorder(line, fecundity, FUN = median),  
y = fecundity, fill = line)) + geom_boxplot() + guides(fill = "none") + 
labs(y ="number of eggs laid per female \n per day for the first 14 days of life", 
x = "") + scale_fill_brewer()
ggplot(data = DROSOPHILA, aes(x = reorder(line, fecundity, FUN = median), 
y = fecundity, fill = line)) + geom_violin() + guides(fill = "none") + 
labs(y ="number of eggs laid per female \n per day for the first 14 days of life", 
x = "") + scale_fill_brewer()
summary(aov(fecundity ~ line, data = DROSOPHILA))
# }

Run the code above in your browser using DataLab