diff --git a/R/calhouse.R b/R/calhouse.R index 22f60bde8cd933fc83a234b3ddc59dcc648c630e..a79cb3f20c19155d3df5b9b3e6c7abac52cee4af 100644 --- a/R/calhouse.R +++ b/R/calhouse.R @@ -2,15 +2,15 @@ #' The data pertains to the houses found in a given California district and some summary stats about them based on the 1990 census data. #' #' -#' @format A dataframe -#' \describe{ +#' @format A dataframe 20640 observations, 14 variables +#' #'\describe{ #'\item{\code{Longitude}}{A measure of how far west a house is; a higher value is farther west} #'\item{\code{Latitude}}{A measure of how far north a house is; a higher value is farther north} #'\item{\code{Median_Age}}{Median age of a house within a block; a lower number is a newer building} #'\item{\code{Tot_Rooms}}{Total number of rooms within a block} #'\item{\code{Tot_Bedrooms}}{Total number of bedrooms within a block} -#'\item{\code{Population}}{Total number of people residing within a block}} +#'\item{\code{Population}}{Total number of people residing within a block} #'\item{\code{Households}}{Total number of households, a group of people residing within a home unit, for a block} #'\item{\code{Median_Income}}{Median income for households within a block of houses (measured in tens of thousands of US Dollars)} #'\item{\code{Median_House_Value}}{Median house value for households within a block (measured in US Dollars)} @@ -22,3 +22,4 @@ #'} "calhouse" + diff --git a/R/testdata.R b/R/testdata.R index 437e705a569a01e184adfc4890aa3d1d7fe5949c..1143b69f908b5faf77e3200c0d952dc776533f2d 100644 --- a/R/testdata.R +++ b/R/testdata.R @@ -1,14 +1,13 @@ -#' Testdata is a dataset with generated values for explanatory purposes -#' -#' Testdata includes infromation about 100 persons and their age, spending habits, gender and income. The values are computer generated via random numbers and some limiters. + +#' Random generated numbers and values for expplanatory purpose. #' #' -#' @format A dataframe with 100 observations and 4 variables: +#' @format A data frame,100 observations, 4 variables #' \describe{ -#' \item{age}{int age in years} -#' \item{spending_habits}{int spendings per month in euro} -#' \item{gender}{chr genderidentity: male, female, nonbinary} -#' \item{income}{int income per month in euro} -#' } +#'\item{\code{age}}{int age in years} +#'\item{\code{spending_habits}}{int spendings per month in euro} +#'\item{\code{income}}{int income per month in euro} +#'\item{\code{gender}}{chr genderidentity: male, female, nonbinary} +#'} -"testdata" # Testdata \ No newline at end of file +"testdata" diff --git a/data-raw/calhouse_load.R b/data-raw/calhouse_load.R index 9bc24adf65f4e506788bc1e5dd6612045863fe5b..2e93ee323780643df3f407625a5db614236c0255 100644 --- a/data-raw/calhouse_load.R +++ b/data-raw/calhouse_load.R @@ -1,10 +1,11 @@ -## code to prepare `DATASET` dataset goes here +## code to prepare `calhouse` dataset goes here + +library(devtools) +library(roxygen2) calhouse <- read.csv("Z://wiso/SozOek_EmpWifo/Gemeinsam/L_Projekte/Data_Science_Kurs_WiSe_2023_24/sozoekds/data-raw/calhouse.csv") usethis::use_data(calhouse, overwrite = TRUE) -devtools::load_all() -examscores -check() + diff --git a/data-raw/examscores_load.R b/data-raw/examscores_load.R index 5c9cba2e016442f08115b3a8eb02aade3e73353e..cb784e3e73ae0ab1f16f7bbef4375c70bd09b259 100644 --- a/data-raw/examscores_load.R +++ b/data-raw/examscores_load.R @@ -1,7 +1,6 @@ -## code to prepare `DATASET` dataset goes here +## code to prepare `examscores` dataset goes here examscores <- read.csv("Z://wiso/SozOek_EmpWifo/Gemeinsam/L_Projekte/Data_Science_Kurs_WiSe_2023_24/sozoekds/data-raw/examscores.csv") -save(examscores, file = "Z://wiso/SozOek_EmpWifo/Gemeinsam/L_Projekte/Data_Science_Kurs_WiSe_2023_24/sozoekds/data/examscores.rda") - +usethis::use_data(examscores, overwrite = TRUE) diff --git a/data-raw/testdata_load.R b/data-raw/testdata_load.R index 6514a9443aae1fa285c22cb004a804d641293a61..310222814ad95368f9724b3946a93d5918c91e71 100644 --- a/data-raw/testdata_load.R +++ b/data-raw/testdata_load.R @@ -1,3 +1,9 @@ -## code to prepare `DATASET` dataset goes here +## code to prepare `testdata` dataset goes here + +library(devtools) +library(roxygen2) + +testdata <- read.csv("Z://wiso/SozOek_EmpWifo/Gemeinsam/L_Projekte/Data_Science_Kurs_WiSe_2023_24/sozoekds/data-raw/testdata.csv") + +usethis::use_data(testdata, overwrite = TRUE) -usethis::use_data(DATASET, overwrite = TRUE) diff --git a/data/examscores.rda b/data/examscores.rda index c9ca08773c5a99ddb739b40872e557f9e670409f..f4a894ed28987aed1f778c9013e5a229e432669e 100644 Binary files a/data/examscores.rda and b/data/examscores.rda differ diff --git a/man/calhouse.Rd b/man/calhouse.Rd index 7389e1c04395a9918295231cd41d4dfd5cfd8ae1..a4a6f70ac3f5bef177d92fcc53620eff098dc7ae 100644 --- a/man/calhouse.Rd +++ b/man/calhouse.Rd @@ -5,15 +5,15 @@ \alias{calhouse} \title{The data pertains to the houses found in a given California district and some summary stats about them based on the 1990 census data.} \format{ -A dataframe -\describe{ +A dataframe 20640 observations, 14 variables + \describe{ \item{\code{Longitude}}{A measure of how far west a house is; a higher value is farther west} \item{\code{Latitude}}{A measure of how far north a house is; a higher value is farther north} \item{\code{Median_Age}}{Median age of a house within a block; a lower number is a newer building} \item{\code{Tot_Rooms}}{Total number of rooms within a block} \item{\code{Tot_Bedrooms}}{Total number of bedrooms within a block} -\item{\code{Population}}{Total number of people residing within a block}} +\item{\code{Population}}{Total number of people residing within a block} \item{\code{Households}}{Total number of households, a group of people residing within a home unit, for a block} \item{\code{Median_Income}}{Median income for households within a block of houses (measured in tens of thousands of US Dollars)} \item{\code{Median_House_Value}}{Median house value for households within a block (measured in US Dollars)} diff --git a/man/examscores.Rd b/man/examscores.Rd index bcaf3c0199ab365900235e018f481c1cc118dae3..dbc35daf9c2bce347d061b2aa57b6d64aba7bf17 100644 --- a/man/examscores.Rd +++ b/man/examscores.Rd @@ -3,9 +3,9 @@ \docType{data} \name{examscores} \alias{examscores} -\title{This dataset includes scores from three test scores of students at a (fictional) public school and a variety of personal and socio-economic factors that may have interaction effects upon them.} +\title{This data set includes scores from three test scores of students at a (fictional) public school and a variety of personal and socio-economic factors that may have interaction effects upon them.} \format{ -A dataframe, 15 variables, 30641 observations +A dat aframe, 30641 observations, 15 variables \describe{ item{\code{Gender}}{Gender of a student (string)} item{\code{EthnicGroup}}{Origin of a student (string)} @@ -27,6 +27,6 @@ item{\code{WritingScore}}{Score in writing (integer)} examscores } \description{ -This dataset includes scores from three test scores of students at a (fictional) public school and a variety of personal and socio-economic factors that may have interaction effects upon them. +This data set includes scores from three test scores of students at a (fictional) public school and a variety of personal and socio-economic factors that may have interaction effects upon them. } \keyword{datasets} diff --git a/man/testdata.Rd b/man/testdata.Rd index 5537955c2c8d5757b14b523dbe0bad9f9b261ce2..2f516bee616108bc9d7447702d509852dfac1354 100644 --- a/man/testdata.Rd +++ b/man/testdata.Rd @@ -3,10 +3,9 @@ \docType{data} \name{testdata} \alias{testdata} -\title{Random numbers for 100 persons for age, gender, income and spending habits} +\title{Random generated numbers and values for expplanatory purpose.} \format{ -A dataframe with 100 rows and 4 variables: -\describe{ +A data frame,100 observations, 4 variables \describe{ \item{\code{age}}{int age in years} \item{\code{spending_habits}}{int spendings per month in euro} @@ -14,13 +13,10 @@ A dataframe with 100 rows and 4 variables: \item{\code{gender}}{chr genderidentity: male, female, nonbinary} } } -\source{ -\url{Quellangabe (hier beispielsweise als Link)} -} \usage{ testdata } \description{ -Random-generated numbers for explanatory purposes. Include data about age, gender, income and spending habits of 100 persons. +Random generated numbers and values for expplanatory purpose. } \keyword{datasets}