R/STAT210prob3.17.R

#' STAT210prob3.17: Car Lease Length
#'
#' A rental care company wants to investigate whether the type of car rented
#' affects the length of the rental period. An experiment is run for one week at
#' a particular location, and 10 rental contracts are selected at random for
#' each car type.
#'
#' @format A data frame with 40 observations (rows) and 4 variables (columns).
#'
#' \tabular{llllr}{
#'   \tab \bold{Column name} \tab \bold{Data type} \tab \bold{Description} \tab \bold{Values}\cr
#'   \code{[,1]} \tab \code{Type_of_Car} \tab character \tab 4 car categories \tab ("Sub-compact"..."Full Size")\cr
#'   \code{[,2]} \tab \code{Days} \tab integer \tab The rental period in days \tab (1 - 10)\cr
#'   \code{[,3]} \tab \code{Sqrt_days} \tab numeric \tab The square root of the lease period \tab (1 - 3.16228)\cr
#'   \code{[,4]} \tab \code{RESI1} \tab numeric \tab Residuals \tab (-0.962723 - 0.917279)
#' }
#'
#' @details
#'
#' This is data from Exercise 3.17 in Design and Analysis of Experiments, 9th
#' Edition, EMEA Edition.
#'
#' @examples
#'
#' # A short summary of the variables
#' summary(STAT210prob3.17)
#'
#' # Get the residuals
#' STAT210prob3.17$Type_of_Car <- as.factor(STAT210prob3.17$Type_of_Car)
#' res <- aov(Sqrt_days ~ Type_of_Car, data = STAT210prob3.17)
#' res$residuals
#'
#' @source Montgomery, D. C. (2019) \emph{Design and Analysis of Experiments,
#' 9th Edition, EMEA Edition}. New York: Wiley.
#'
#' @docType data
#' @keywords datasets
#' @name STAT210prob3.17
#' @usage STAT210prob3.17
#'
"STAT210prob3.17"
thoree/stat340 documentation built on June 30, 2024, 4:04 p.m.