From 2eee253dc7164416766fcff4a4d16a528dfde17b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mine=20=C3=87etinkaya-Rundel?= Date: Mon, 30 Sep 2019 13:28:46 +0100 Subject: [PATCH 1/9] Clarify nrow in function title --- R/data.R | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/R/data.R b/R/data.R index aee286cc57..72b6e76910 100644 --- a/R/data.R +++ b/R/data.R @@ -1,4 +1,4 @@ -#' Prices of 50,000 round cut diamonds +#' Prices of over 50,000 round cut diamonds #' #' A dataset containing the prices and other attributes of almost 54,000 #' diamonds. The variables are as follows: From 0d2b62ada49189fe0345fac305e8335becd89c8b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mine=20=C3=87etinkaya-Rundel?= Date: Mon, 30 Sep 2019 13:28:55 +0100 Subject: [PATCH 2/9] Correct nrow --- R/data.R | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/R/data.R b/R/data.R index 72b6e76910..789dc5350f 100644 --- a/R/data.R +++ b/R/data.R @@ -26,7 +26,7 @@ #' \url{http://research.stlouisfed.org/fred2}. `economics` is in "wide" #' format, `economics_long` is in "long" format. #' -#' @format A data frame with 478 rows and 6 variables +#' @format A data frame with 574 rows and 6 variables #' \describe{ #' \item{date}{Month of data collection} #' \item{psavert}{personal savings rate, From 660a38d9e9b7d7c21f43cf61729677a49a7561a6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mine=20=C3=87etinkaya-Rundel?= Date: Mon, 30 Sep 2019 13:29:31 +0100 Subject: [PATCH 3/9] Reorder variables in docs to match order in data --- R/data.R | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/R/data.R b/R/data.R index 789dc5350f..31a9dce455 100644 --- a/R/data.R +++ b/R/data.R @@ -29,16 +29,16 @@ #' @format A data frame with 574 rows and 6 variables #' \describe{ #' \item{date}{Month of data collection} -#' \item{psavert}{personal savings rate, -#' \url{http://research.stlouisfed.org/fred2/series/PSAVERT/}} #' \item{pce}{personal consumption expenditures, in billions of dollars, #' \url{http://research.stlouisfed.org/fred2/series/PCE}} -#' \item{unemploy}{number of unemployed in thousands, -#' \url{http://research.stlouisfed.org/fred2/series/UNEMPLOY}} -#' \item{uempmed}{median duration of unemployment, in weeks, -#' \url{http://research.stlouisfed.org/fred2/series/UEMPMED}} #' \item{pop}{total population, in thousands, #' \url{http://research.stlouisfed.org/fred2/series/POP}} +#' \item{psavert}{personal savings rate, +#' \url{http://research.stlouisfed.org/fred2/series/PSAVERT/}} +#' \item{uempmed}{median duration of unemployment, in weeks, +#' \url{http://research.stlouisfed.org/fred2/series/UEMPMED}} +#' \item{unemploy}{number of unemployed in thousands, +#' \url{http://research.stlouisfed.org/fred2/series/UNEMPLOY}} #' } #' "economics" From 3a4bef804a48badd1e57aef682e961584cbde0bc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mine=20=C3=87etinkaya-Rundel?= Date: Mon, 30 Sep 2019 13:44:15 +0100 Subject: [PATCH 4/9] Minor edit to clarify "between" --- R/data.R | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/R/data.R b/R/data.R index 31a9dce455..55dbfe3102 100644 --- a/R/data.R +++ b/R/data.R @@ -85,7 +85,7 @@ "midwest" -#' Fuel economy data from 1999 and 2008 for 38 popular models of car +#' Fuel economy data from 1999 to 2008 for 38 popular models of cars #' #' This dataset contains a subset of the fuel economy data that the EPA makes #' available on \url{http://fueleconomy.gov}. It contains only models which From b8c56aa0fe593392bbc473fd5adac997f0f08a23 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mine=20=C3=87etinkaya-Rundel?= Date: Mon, 30 Sep 2019 13:49:05 +0100 Subject: [PATCH 5/9] Add names of variables --- R/data.R | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/R/data.R b/R/data.R index 55dbfe3102..acb8bf38c2 100644 --- a/R/data.R +++ b/R/data.R @@ -141,6 +141,12 @@ #' their party of 11 US presidents from Eisenhower to Obama. #' #' @format A data frame with 11 rows and 4 variables +#' \describe{ +#' \item{name}{Last name of president} +#' \item{start}{Presidency start date} +#' \item{end}{Presidency end date} +#' \item{party}{Party of president} +#' } "presidential" #' Vector field of seal movements @@ -162,6 +168,11 @@ #' \link{faithful}. #' #' @format A data frame with 5,625 observations and 3 variables. +#' \describe{ +#' \item{eruptions}{Eruption time in mins} +#' \item{waiting}{Waiting time to next eruption in mins} +#' \item{density}{2d density estimate} +#' } "faithfuld" #' `colors()` in Luv space From c202d8331fc7fd6811bc9be36f28dd330770f833 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mine=20=C3=87etinkaya-Rundel?= Date: Mon, 30 Sep 2019 14:30:39 +0100 Subject: [PATCH 6/9] Say what MLS means --- R/data.R | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/R/data.R b/R/data.R index acb8bf38c2..5948b52b38 100644 --- a/R/data.R +++ b/R/data.R @@ -193,7 +193,7 @@ #' #' @format A data frame with 8602 observations and 9 variables: #' \describe{ -#' \item{city}{Name of MLS area} +#' \item{city}{Name of multiple listing service (MLS) area} #' \item{year,month,date}{Date} #' \item{sales}{Number of sales} #' \item{volume}{Total value of sales} From 294f8f4cd6899e3d2af34cd03c934f927792558f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mine=20=C3=87etinkaya-Rundel?= Date: Mon, 30 Sep 2019 15:14:42 +0100 Subject: [PATCH 7/9] Add var description --- R/data.R | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/R/data.R b/R/data.R index 5948b52b38..a179342cc2 100644 --- a/R/data.R +++ b/R/data.R @@ -94,7 +94,7 @@ #' #' @format A data frame with 234 rows and 11 variables #' \describe{ -#' \item{manufacturer}{} +#' \item{manufacturer}{manufacturer name} #' \item{model}{model name} #' \item{displ}{engine displacement, in litres} #' \item{year}{year of manufacture} From db3dffb1d0bc58e0169af89abafc426c3314dec8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mine=20=C3=87etinkaya-Rundel?= Date: Mon, 30 Sep 2019 15:19:15 +0100 Subject: [PATCH 8/9] Run document() --- man/diamonds.Rd | 2 +- man/economics.Rd | 14 +++++++------- man/faithfuld.Rd | 7 ++++++- man/mpg.Rd | 4 ++-- man/presidential.Rd | 8 +++++++- man/txhousing.Rd | 2 +- 6 files changed, 24 insertions(+), 13 deletions(-) diff --git a/man/diamonds.Rd b/man/diamonds.Rd index 8d2cb9c0b7..ed13e7e846 100644 --- a/man/diamonds.Rd +++ b/man/diamonds.Rd @@ -3,7 +3,7 @@ \docType{data} \name{diamonds} \alias{diamonds} -\title{Prices of 50,000 round cut diamonds} +\title{Prices of over 50,000 round cut diamonds} \format{A data frame with 53940 rows and 10 variables: \describe{ \item{price}{price in US dollars (\$326--\$18,823)} diff --git a/man/economics.Rd b/man/economics.Rd index 50dc689d90..7dc63c0921 100644 --- a/man/economics.Rd +++ b/man/economics.Rd @@ -5,19 +5,19 @@ \alias{economics} \alias{economics_long} \title{US economic time series} -\format{A data frame with 478 rows and 6 variables +\format{A data frame with 574 rows and 6 variables \describe{ \item{date}{Month of data collection} -\item{psavert}{personal savings rate, -\url{http://research.stlouisfed.org/fred2/series/PSAVERT/}} \item{pce}{personal consumption expenditures, in billions of dollars, \url{http://research.stlouisfed.org/fred2/series/PCE}} -\item{unemploy}{number of unemployed in thousands, -\url{http://research.stlouisfed.org/fred2/series/UNEMPLOY}} -\item{uempmed}{median duration of unemployment, in weeks, -\url{http://research.stlouisfed.org/fred2/series/UEMPMED}} \item{pop}{total population, in thousands, \url{http://research.stlouisfed.org/fred2/series/POP}} +\item{psavert}{personal savings rate, +\url{http://research.stlouisfed.org/fred2/series/PSAVERT/}} +\item{uempmed}{median duration of unemployment, in weeks, +\url{http://research.stlouisfed.org/fred2/series/UEMPMED}} +\item{unemploy}{number of unemployed in thousands, +\url{http://research.stlouisfed.org/fred2/series/UNEMPLOY}} }} \usage{ economics diff --git a/man/faithfuld.Rd b/man/faithfuld.Rd index 440b3999d1..27e203ea67 100644 --- a/man/faithfuld.Rd +++ b/man/faithfuld.Rd @@ -4,7 +4,12 @@ \name{faithfuld} \alias{faithfuld} \title{2d density estimate of Old Faithful data} -\format{A data frame with 5,625 observations and 3 variables.} +\format{A data frame with 5,625 observations and 3 variables. +\describe{ +\item{eruptions}{Eruption time in mins} +\item{waiting}{Waiting time to next eruption in mins} +\item{density}{2d density estimate} +}} \usage{ faithfuld } diff --git a/man/mpg.Rd b/man/mpg.Rd index 63b4f8ca44..47846e9e29 100644 --- a/man/mpg.Rd +++ b/man/mpg.Rd @@ -3,10 +3,10 @@ \docType{data} \name{mpg} \alias{mpg} -\title{Fuel economy data from 1999 and 2008 for 38 popular models of car} +\title{Fuel economy data from 1999 to 2008 for 38 popular models of cars} \format{A data frame with 234 rows and 11 variables \describe{ -\item{manufacturer}{} +\item{manufacturer}{manufacturer name} \item{model}{model name} \item{displ}{engine displacement, in litres} \item{year}{year of manufacture} diff --git a/man/presidential.Rd b/man/presidential.Rd index f3de3abdf8..b61b014946 100644 --- a/man/presidential.Rd +++ b/man/presidential.Rd @@ -4,7 +4,13 @@ \name{presidential} \alias{presidential} \title{Terms of 11 presidents from Eisenhower to Obama} -\format{A data frame with 11 rows and 4 variables} +\format{A data frame with 11 rows and 4 variables +\describe{ +\item{name}{Last name of president} +\item{start}{Presidency start date} +\item{end}{Presidency end date} +\item{party}{Party of president} +}} \usage{ presidential } diff --git a/man/txhousing.Rd b/man/txhousing.Rd index 5ae08e29fe..e9183ea37c 100644 --- a/man/txhousing.Rd +++ b/man/txhousing.Rd @@ -6,7 +6,7 @@ \title{Housing sales in TX} \format{A data frame with 8602 observations and 9 variables: \describe{ -\item{city}{Name of MLS area} +\item{city}{Name of multiple listing service (MLS) area} \item{year,month,date}{Date} \item{sales}{Number of sales} \item{volume}{Total value of sales} From f9aba545b2ecb977213c59b53669e7832704e373 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mine=20=C3=87etinkaya-Rundel?= Date: Tue, 1 Oct 2019 00:35:17 +0100 Subject: [PATCH 9/9] Align punctuation before list of variables --- R/data.R | 12 ++++++------ man/economics.Rd | 2 +- man/faithfuld.Rd | 2 +- man/midwest.Rd | 2 +- man/mpg.Rd | 2 +- man/msleep.Rd | 2 +- man/presidential.Rd | 2 +- 7 files changed, 12 insertions(+), 12 deletions(-) diff --git a/R/data.R b/R/data.R index a179342cc2..19ff85b59d 100644 --- a/R/data.R +++ b/R/data.R @@ -26,7 +26,7 @@ #' \url{http://research.stlouisfed.org/fred2}. `economics` is in "wide" #' format, `economics_long` is in "long" format. #' -#' @format A data frame with 574 rows and 6 variables +#' @format A data frame with 574 rows and 6 variables: #' \describe{ #' \item{date}{Month of data collection} #' \item{pce}{personal consumption expenditures, in billions of dollars, @@ -50,7 +50,7 @@ #' #' Demographic information of midwest counties #' -#' @format A data frame with 437 rows and 28 variables +#' @format A data frame with 437 rows and 28 variables: #' \describe{ #' \item{PID}{} #' \item{county}{} @@ -92,7 +92,7 @@ #' had a new release every year between 1999 and 2008 - this was used as a #' proxy for the popularity of the car. #' -#' @format A data frame with 234 rows and 11 variables +#' @format A data frame with 234 rows and 11 variables: #' \describe{ #' \item{manufacturer}{manufacturer name} #' \item{model}{model name} @@ -119,7 +119,7 @@ #' Additional variables order, conservation status and vore were added from #' wikipedia. #' -#' @format A data frame with 83 rows and 11 variables +#' @format A data frame with 83 rows and 11 variables: #' \describe{ #' \item{name}{common name} #' \item{genus}{} @@ -140,7 +140,7 @@ #' The names of each president, the start and end date of their term, and #' their party of 11 US presidents from Eisenhower to Obama. #' -#' @format A data frame with 11 rows and 4 variables +#' @format A data frame with 11 rows and 4 variables: #' \describe{ #' \item{name}{Last name of president} #' \item{start}{Presidency start date} @@ -167,7 +167,7 @@ #' A 2d density estimate of the waiting and eruptions variables data #' \link{faithful}. #' -#' @format A data frame with 5,625 observations and 3 variables. +#' @format A data frame with 5,625 observations and 3 variables: #' \describe{ #' \item{eruptions}{Eruption time in mins} #' \item{waiting}{Waiting time to next eruption in mins} diff --git a/man/economics.Rd b/man/economics.Rd index 7dc63c0921..e099d23e8e 100644 --- a/man/economics.Rd +++ b/man/economics.Rd @@ -5,7 +5,7 @@ \alias{economics} \alias{economics_long} \title{US economic time series} -\format{A data frame with 574 rows and 6 variables +\format{A data frame with 574 rows and 6 variables: \describe{ \item{date}{Month of data collection} \item{pce}{personal consumption expenditures, in billions of dollars, diff --git a/man/faithfuld.Rd b/man/faithfuld.Rd index 27e203ea67..a5d8d0b7d0 100644 --- a/man/faithfuld.Rd +++ b/man/faithfuld.Rd @@ -4,7 +4,7 @@ \name{faithfuld} \alias{faithfuld} \title{2d density estimate of Old Faithful data} -\format{A data frame with 5,625 observations and 3 variables. +\format{A data frame with 5,625 observations and 3 variables: \describe{ \item{eruptions}{Eruption time in mins} \item{waiting}{Waiting time to next eruption in mins} diff --git a/man/midwest.Rd b/man/midwest.Rd index f5ccf869dc..ee8b5e85ae 100644 --- a/man/midwest.Rd +++ b/man/midwest.Rd @@ -4,7 +4,7 @@ \name{midwest} \alias{midwest} \title{Midwest demographics} -\format{A data frame with 437 rows and 28 variables +\format{A data frame with 437 rows and 28 variables: \describe{ \item{PID}{} \item{county}{} diff --git a/man/mpg.Rd b/man/mpg.Rd index 47846e9e29..ec696861bd 100644 --- a/man/mpg.Rd +++ b/man/mpg.Rd @@ -4,7 +4,7 @@ \name{mpg} \alias{mpg} \title{Fuel economy data from 1999 to 2008 for 38 popular models of cars} -\format{A data frame with 234 rows and 11 variables +\format{A data frame with 234 rows and 11 variables: \describe{ \item{manufacturer}{manufacturer name} \item{model}{model name} diff --git a/man/msleep.Rd b/man/msleep.Rd index 682992290e..a53c1cd3e2 100644 --- a/man/msleep.Rd +++ b/man/msleep.Rd @@ -4,7 +4,7 @@ \name{msleep} \alias{msleep} \title{An updated and expanded version of the mammals sleep dataset} -\format{A data frame with 83 rows and 11 variables +\format{A data frame with 83 rows and 11 variables: \describe{ \item{name}{common name} \item{genus}{} diff --git a/man/presidential.Rd b/man/presidential.Rd index b61b014946..4c827f93aa 100644 --- a/man/presidential.Rd +++ b/man/presidential.Rd @@ -4,7 +4,7 @@ \name{presidential} \alias{presidential} \title{Terms of 11 presidents from Eisenhower to Obama} -\format{A data frame with 11 rows and 4 variables +\format{A data frame with 11 rows and 4 variables: \describe{ \item{name}{Last name of president} \item{start}{Presidency start date}