diff --git a/.Rbuildignore b/.Rbuildignore index a6e05fd..c3f3759 100644 --- a/.Rbuildignore +++ b/.Rbuildignore @@ -12,3 +12,4 @@ ^cache$ ^\.github$ ^cran-comments\.md$ +^CRAN-SUBMISSION$ diff --git a/DESCRIPTION b/DESCRIPTION index 849249b..baee0a9 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,7 +1,7 @@ Type: Package Package: debkeepr Title: Analysis of Non-Decimal Currencies and Double-Entry Bookkeeping -Version: 0.1.0 +Version: 0.1.1 Authors@R: person("Jesse", "Sadler", , "jrsadler@icloud.com", role = c("aut", "cre", "cph"), comment = c(ORCID = "0000-0001-6081-9681")) @@ -33,6 +33,7 @@ Suggests: igraph, knitr, rmarkdown, + roxygen2, scales (>= 1.1.0), testthat (>= 3.1.3) VignetteBuilder: diff --git a/NEWS.md b/NEWS.md index 6701960..68a4cdc 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,4 +1,9 @@ +# debkeepr 0.1.1 + +- Documentation fixes for CRAN checks. + # debkeepr 0.1.0 + - Prep for CRAN release. - Transaction functions now return a data.frame if input is data.frame. - Make all tests self-sufficient. diff --git a/R/arithmetic.R b/R/arithmetic.R index 9edf86c..02a0f72 100644 --- a/R/arithmetic.R +++ b/R/arithmetic.R @@ -4,6 +4,8 @@ #' @param x,y Vectors. #' @param op Arithmetic operation. #' @param ... For future expansion +#' @returns A `deb_lsd`, `deb_tetra`, `deb_decimal` or `numeric` vector +#' depending on the inputs and arithmetic operator. #' @name arithmetic NULL diff --git a/R/comparison.R b/R/comparison.R index d2b442c..dad4971 100644 --- a/R/comparison.R +++ b/R/comparison.R @@ -5,6 +5,7 @@ #' Equality and comparison #' @param x A deb_lsd vector. #' @param ... Arguments passed on to further methods. +#' @returns A data frame or numeric vector to be used for comparison. #' @name comparison NULL diff --git a/R/debkeepr-package.R b/R/debkeepr-package.R index 5cc3017..2b199fb 100644 --- a/R/debkeepr-package.R +++ b/R/debkeepr-package.R @@ -15,6 +15,7 @@ NULL #' @name %<-% #' @rdname multi-assign #' @keywords internal +#' @returns Invisibly returns `value`. #' @export #' @importFrom zeallot %<-% #' @usage x \%<-\% value @@ -23,7 +24,7 @@ NULL #' Pipe operator #' -#' See \code{magrittr::\link[magrittr]{\%>\%}} for details. +#' See \code{magrittr::\link[magrittr:pipe]{\%>\%}} for details. #' #' @name %>% #' @rdname pipe @@ -31,6 +32,9 @@ NULL #' @export #' @importFrom magrittr %>% #' @usage lhs \%>\% rhs +#' @param lhs A value or the magrittr placeholder. +#' @param rhs A function call using the magrittr semantics. +#' @return The result of calling `rhs(lhs)`. NULL #' Tidy eval helpers diff --git a/R/mathematics.R b/R/mathematics.R index 5162ae8..1d0445e 100644 --- a/R/mathematics.R +++ b/R/mathematics.R @@ -197,6 +197,7 @@ trunc.deb_lsd <- function(x, ...) { #' @param .fn A mathematical function from the base package. #' @param .x A vector. #' @param ... Additional arguments passed to `.fn`. +#' @returns A `deb_lsd` vector. #' @export vec_math.deb_lsd <- function(.fn, .x, ...) { # Implement sum to allow various types of deb-style vectors in ... @@ -332,6 +333,7 @@ trunc.deb_tetra <- function(x, ...) { #' @param .fn A mathematical function from the base package. #' @param .x A vector. #' @param ... Additional arguments passed to `.fn`. +#' @returns A `deb_tetra` vector. #' @export vec_math.deb_tetra <- function(.fn, .x, ...) { # Implement sum to allow various types of deb-style vectors in ... diff --git a/cran-comments.md b/cran-comments.md index 8ecd3ee..70a9ab5 100644 --- a/cran-comments.md +++ b/cran-comments.md @@ -1,3 +1,19 @@ +## Resubmission + +There are currently no references describing the methods in the package. I am currently working on writing a methods paper and will include it in a future update. + +This is a resubmission. In this version I have: + +* Added \value to the following .Rd files: + * arithmetic.Rd + * comparison.Rd + * multi-assign.Rd + * pipe.Rd + * vec_math.deb_lsd.Rd + * vec_math.deb_tetra.Rd + +* I have added \arguments to pipe.Rd + ## R CMD check results 0 errors | 0 warnings | 3 note diff --git a/man/arithmetic.Rd b/man/arithmetic.Rd index ab0d89f..59c9864 100644 --- a/man/arithmetic.Rd +++ b/man/arithmetic.Rd @@ -83,6 +83,10 @@ \item{...}{For future expansion} } +\value{ +A \code{deb_lsd}, \code{deb_tetra}, \code{deb_decimal} or \code{numeric} vector +depending on the inputs and arithmetic operator. +} \description{ Arithmetic operations for debkeepr } diff --git a/man/comparison.Rd b/man/comparison.Rd index f8b5841..71ae071 100644 --- a/man/comparison.Rd +++ b/man/comparison.Rd @@ -21,6 +21,9 @@ \item{...}{Arguments passed on to further methods.} } +\value{ +A data frame or numeric vector to be used for comparison. +} \description{ Equality and comparison } diff --git a/man/multi-assign.Rd b/man/multi-assign.Rd index df41e58..4487957 100644 --- a/man/multi-assign.Rd +++ b/man/multi-assign.Rd @@ -6,6 +6,9 @@ \usage{ x \%<-\% value } +\value{ +Invisibly returns \code{value}. +} \description{ See \code{\link[zeallot]{\%<-\%}} for more details. } diff --git a/man/pipe.Rd b/man/pipe.Rd index e947570..3e27233 100644 --- a/man/pipe.Rd +++ b/man/pipe.Rd @@ -6,7 +6,15 @@ \usage{ lhs \%>\% rhs } +\arguments{ +\item{lhs}{A value or the magrittr placeholder.} + +\item{rhs}{A function call using the magrittr semantics.} +} +\value{ +The result of calling \code{rhs(lhs)}. +} \description{ -See \code{magrittr::\link[magrittr]{\%>\%}} for details. +See \code{magrittr::\link[magrittr:pipe]{\%>\%}} for details. } \keyword{internal} diff --git a/man/vec_math.deb_lsd.Rd b/man/vec_math.deb_lsd.Rd index 4da6247..f271004 100644 --- a/man/vec_math.deb_lsd.Rd +++ b/man/vec_math.deb_lsd.Rd @@ -13,6 +13,9 @@ \item{...}{Additional arguments passed to \code{.fn}.} } +\value{ +A \code{deb_lsd} vector. +} \description{ Error message for unimplemented mathematics functions } diff --git a/man/vec_math.deb_tetra.Rd b/man/vec_math.deb_tetra.Rd index 61737c5..7d28b2d 100644 --- a/man/vec_math.deb_tetra.Rd +++ b/man/vec_math.deb_tetra.Rd @@ -13,6 +13,9 @@ \item{...}{Additional arguments passed to \code{.fn}.} } +\value{ +A \code{deb_tetra} vector. +} \description{ Error message for unimplemented mathematics functions }