diff --git a/DESCRIPTION b/DESCRIPTION index 1aedd43..ea86832 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,6 +1,6 @@ Package: aion Title: Archaeological Time Series -Version: 1.0.0 +Version: 1.0.1 Authors@R: c( person("Nicolas", "Frerebeau", , "nicolas.frerebeau@u-bordeaux-montaigne.fr", role = c("aut", "cre"), comment = c(ORCID = "0000-0001-5759-4944", affiliation = "Université Bordeaux Montaigne")), @@ -21,7 +21,7 @@ URL: https://packages.tesselle.org/aion/, https://github.com/tesselle/aion BugReports: https://github.com/tesselle/aion/issues Depends: R (>= 3.3) -Imports: arkhe, graphics, grDevices, methods +Imports: arkhe (>= 1.2.0), graphics, grDevices, methods Suggests: knitr, rmarkdown, rsvg, svglite, tinysnapshot, tinytest VignetteBuilder: knitr Encoding: UTF-8 @@ -33,11 +33,11 @@ Collate: 'AllClasses.R' 'AllGenerics.R' 'aion-internal.R' 'operators.R' 'plot.R' 'series.R' 'show.R' 'subset.R' 'time.R' 'validate.R' 'years.R' 'zzz.R' NeedsCompilation: no -Packaged: 2023-06-12 15:49:02 UTC; nicolas +Packaged: 2023-08-22 12:29:54 UTC; nicolas Author: Nicolas Frerebeau [aut, cre] (, Université Bordeaux Montaigne), Joe Roe [aut] (, Universität Bern), Brice Lebrun [ctb] () Repository: CRAN -Date/Publication: 2023-06-13 08:10:07 UTC +Date/Publication: 2023-08-22 13:20:06 UTC diff --git a/MD5 b/MD5 index 8f4b771..f97f74d 100644 --- a/MD5 +++ b/MD5 @@ -1,10 +1,10 @@ -5d2b53c1b1d86c73136d92a804adc304 *DESCRIPTION +fa4ea8bbfdd437726eb9b80f9f74c439 *DESCRIPTION c86f326ba18234f6525c1105935f3d19 *NAMESPACE -e5a0f835e720e71940f3d1db2d3765b0 *NEWS.md +a6f6bbe979140e2e9b6f7c3f78f87e8d *NEWS.md 67960379b200bfe9aa8551629b7438aa *R/AllClasses.R -d6ed79219a7b26be5c4ef90c775b952a *R/AllGenerics.R +446910517e46c1374bf711f7d92914a5 *R/AllGenerics.R d38656be290fc75e1397c02d17dad773 *R/aion-internal.R -c0ad5ccb3b679a12cc238855525334e1 *R/aion-package.R +9d42a29455c74af54599f5f535417e0a *R/aion-package.R 867ae0303a7ba79337c671554188f8eb *R/calendar-gregorian.R e57e25362b28aa0a30a778b47861295f *R/calendar-julian.R a1892ab0eeda755a2e7271606e127858 *R/calendar.R @@ -13,7 +13,7 @@ a1892ab0eeda755a2e7271606e127858 *R/calendar.R 04ffc4a2693131e7a2082e059b961f5d *R/data.R 3885bdf16134fb80d9f885a2c93a6aa0 *R/mutators.R 1b96b10ba44344b4742dd0122221b7d6 *R/operators.R -fbe9b5120a01326e649d78d7052a5ada *R/plot.R +966ef90cbe745df16eba048da6628f1b *R/plot.R 20835ca69fc0e29f18693358d15d147c *R/series.R ccddcf756920a2721d9254965dfab749 *R/show.R 120c05ad32491be24ee55207641add03 *R/subset.R @@ -21,20 +21,20 @@ ccddcf756920a2721d9254965dfab749 *R/show.R 5fddcd20cb47f4bfbb50afb8834befc2 *R/validate.R b27459412d6cfda6e7d74255c4366007 *R/years.R 958b1e7880269969e082958ea8dffddf *R/zzz.R -2702a67de81aa73965c6cac3b982ecd0 *README.md -439bf689fa27cf9affd0335332142165 *build/partial.rdb -61682881e88fca95f84ba15e696321d5 *build/vignette.rds +94c8bbcca0696fe20302e68d9e47fdef *README.md +7080893e02c49cd296d4424b9be55069 *build/partial.rdb +76ae13cd86bd563b19ca20cb61c9e2d5 *build/vignette.rds 7821d926987c8529109c3aa2f74a50c0 *data/dates.rda -7a6c2fb7732b82f449b41a04f14ed49a *inst/CITATION +ded1411252f430084e356392715bdf1d *inst/CITATION a84f50702f9ad242da4df77d2b4dd2f1 *inst/doc/aion.R 63aee94a51d8aaab9139b45315816ce0 *inst/doc/aion.Rmd -d430dba07ab2cea126d68a6a9cce8bd6 *inst/doc/aion.html +be0a9944b5e25211c9a4f09ce5691a4f *inst/doc/aion.html 46750e778a5cdb4d65c347f8e43df623 *inst/doc/bibliography.R 1ce99d6139b36c341c6a9f8c293c7b24 *inst/doc/bibliography.Rmd -d811ce583f3427e89330b77598e6bfe9 *inst/doc/bibliography.html +2d59ea48aeba6e3c9cc2f4afeb93f552 *inst/doc/bibliography.html 437b98c8ab52986e88ef007d96ed1186 *inst/doc/extending.R fb7cbe03ee29ac49bdeb5bf8a075dfd0 *inst/doc/extending.Rmd -62a6dd420b5f1a8a41c361173a2cd367 *inst/doc/extending.html +c0d1fe4e851b4b26032eb4957faaedef *inst/doc/extending.html b6df944a691946342c9c4cf20469b97f *inst/examples/ex-arith.R 4b8b1a6a41d5b8208582b493cef2c30e *inst/examples/ex-axis.R ff525a5ae8022028c01805334c548649 *inst/examples/ex-calendar.R @@ -80,7 +80,7 @@ d03ffb3c4be8c5957ace6bb965bd2aaf *man/BP-class.Rd 526f4aca74cafd221b40801e8f31bc9c *man/RataDie-class.Rd 32c76b530fee710bc27276f6a238dd58 *man/TimeScale-class.Rd 0f5940509c0fe99ab1e531aca1a43d79 *man/TimeSeries-class.Rd -1242c31c176e2fbe56e67d89960001ac *man/aion-package.Rd +6a3bc23cebb6fb064fa6082fa743bd9d *man/aion-package.Rd 28f8e7cee50e1a369a6df23d0554df6e *man/arithmetic.Rd aa97a7c0249003d54ff4c7f783c389e3 *man/as_date.Rd 3f987dadfc8033b43d59c81282463c26 *man/as_decimal.Rd @@ -105,7 +105,7 @@ dfc91cf91a638a4ea5cce1ae5bc98022 *man/gregorian.Rd 60499796e6c4aca1bf1418a4646b9dd7 *man/julian.Rd 33af9a3b552f75b45d0e96ada33fbba4 *man/plot.Rd cd920650b0333b7e33787d5aca4d7055 *man/pretty.Rd -1b3563f69eb2d03549b85deb4503ee44 *man/series.Rd +7186ca471db14dc172bdee5327f5ce49 *man/series.Rd 790d3d636f529aa4faf42add2293324b *man/span.Rd 780f3cf5452614a6797b9caf5e2711b6 *man/start.Rd 02a43b46e3ab8b66893689c34322624d *man/subset.Rd diff --git a/NEWS.md b/NEWS.md index 35e0836..87560f2 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,3 +1,7 @@ +# aion 1.0.1 +## Bugfixes & changes +* `plot()` now supports missing values. + # aion 1.0.0 * First release. diff --git a/R/AllGenerics.R b/R/AllGenerics.R index e0af5ab..3b86b6d 100644 --- a/R/AllGenerics.R +++ b/R/AllGenerics.R @@ -452,8 +452,8 @@ NULL #' Create Time Series #' #' @param object A [`numeric`] `vector`, `matrix` or `array` of the observed -#' time-series values. -#' A [`data.frame`] will be coerced to a `numeric` `matrix` via [data.matrix()]. +#' time-series values. A [`data.frame`] will be coerced to a `numeric` `matrix` +#' via [data.matrix()]. #' @param time A [`numeric`] vector of (decimal) years or a [`RataDie-class`] #' object (see [fixed()]). #' @param calendar A [`TimeScale-class`] object specifying the calendar of diff --git a/R/aion-package.R b/R/aion-package.R index 06c7bf4..ec3aca3 100644 --- a/R/aion-package.R +++ b/R/aion-package.R @@ -2,8 +2,9 @@ #' \tabular{ll}{ #' **Package:** \tab aion \cr #' **Type:** \tab Package \cr -#' **Version:** \tab 1.0.0 \cr +#' **Version:** \tab 1.0.1 \cr #' **License:** \tab GPL-3 \cr +#' **Zenodo:** \tab \doi{10.5281/zenodo.8032278} \cr #' } #' #' @section Package options: diff --git a/R/plot.R b/R/plot.R index 504cfa3..fe118e3 100644 --- a/R/plot.R +++ b/R/plot.R @@ -100,7 +100,7 @@ setMethod("plot", c(x = "TimeSeries", y = "missing"), plot.TimeSeries) ## Set plotting coordinates years <- time(x, calendar = calendar) xlim <- xlim %||% xlim(x, calendar = calendar) - ylim <- ylim %||% range(x) + ylim <- ylim %||% range(x, na.rm = TRUE) graphics::plot.window(xlim = xlim, ylim = ylim) ## Evaluate pre-plot expressions @@ -152,6 +152,8 @@ setMethod("plot", c(x = "TimeSeries", y = "missing"), plot.TimeSeries) #' The default is [graphics::lines()]. #' @param y_flip A [`logical`] scalar: should the y-axis (ticks and numbering) #' be flipped from side 2 (left) to 4 (right) from series to series? +#' @param y_fixed A [`logical`] scalar: should the y-scale be shared across +#' all series? #' @param ncol An [`integer`] specifying the number of columns to use. #' Defaults to 1 for up to 4 series, otherwise to 2. #' @param main A [`character`] string giving a main title for the plot. @@ -174,7 +176,7 @@ setMethod("plot", c(x = "TimeSeries", y = "missing"), plot.TimeSeries) #' @keywords internal #' @noRd .plot_multiple <- function(x, calendar, panel = graphics::lines, - y_flip = TRUE, n_col = NULL, + y_flip = TRUE, y_fixed = FALSE, n_col = NULL, xlab = NULL, ylab = NULL, main = NULL, sub = NULL, ann = graphics::par("ann"), axes = TRUE, @@ -211,12 +213,13 @@ setMethod("plot", c(x = "TimeSeries", y = "missing"), plot.TimeSeries) years <- time(x, calendar = calendar) xlim <- xlim(x, calendar = calendar) + ylim <- if (y_fixed) range(x, na.rm = TRUE) else NULL ylabs <- ylab %||% colnames(x) %||% paste("Series", n_seq, sep = " ") for (j in n_seq) { ## Plot xj <- x[, j, , drop = FALSE] .plot_single(xj, calendar = calendar, panel = panel, - xlim = xlim, ylim = NULL, + xlim = xlim, ylim = ylim, main = NULL, sub = NULL, ann = FALSE, axes = FALSE, frame.plot = frame.plot, panel.first = panel.first, panel.last = panel.last, ...) @@ -357,4 +360,3 @@ year_axis <- function(side, at = NULL, format = c("a", "ka", "Ma", "Ga"), graphics::axis(side, at = as.numeric(at), labels = labels, ...) } - diff --git a/README.md b/README.md index dc74348..fa96ffe 100644 --- a/README.md +++ b/README.md @@ -8,14 +8,27 @@ [![R-CMD-check](https://github.com/tesselle/aion/workflows/R-CMD-check/badge.svg)](https://github.com/tesselle/aion/actions) [![codecov](https://codecov.io/gh/tesselle/aion/branch/main/graph/badge.svg?token=UgoOXsZW86)](https://app.codecov.io/gh/tesselle/aion) [![CodeFactor](https://www.codefactor.io/repository/github/tesselle/aion/badge/main)](https://www.codefactor.io/repository/github/tesselle/aion/overview/main) +[![Dependencies](https://tinyverse.netlify.com/badge/aion)](https://cran.r-project.org/package=aion) r-universe +CRAN Version + + [![Project Status: Active – The project has reached a stable, usable state and is being actively developed.](https://www.repostatus.org/badges/latest/active.svg)](https://www.repostatus.org/#active) + +[![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.8032278.svg)](https://doi.org/10.5281/zenodo.8032278) ## Overview @@ -43,8 +56,9 @@ offers a simple API that can be used by other specialized packages. To cite aion in publications use: Frerebeau N, Roe J (2023). _aion: Archaeological Time Series_. - Université Bordeaux Montaigne, Pessac, France. R package version - 1.0.0, . + Université Bordeaux Montaigne, Pessac, France. + doi:10.5281/zenodo.8032278 , + R package version 1.0.1, . Une entrée BibTeX pour les utilisateurs LaTeX est @@ -54,8 +68,9 @@ offers a simple API that can be used by other specialized packages. year = {2023}, organization = {Université Bordeaux Montaigne}, address = {Pessac, France}, - note = {R package version 1.0.0}, + note = {R package version 1.0.1}, url = {https://packages.tesselle.org/aion/}, + doi = {10.5281/zenodo.8032278}, } This package is a part of the tesselle project diff --git a/build/partial.rdb b/build/partial.rdb index c7c2cee..0456224 100644 Binary files a/build/partial.rdb and b/build/partial.rdb differ diff --git a/build/vignette.rds b/build/vignette.rds index 636f8d6..1f70ed1 100644 Binary files a/build/vignette.rds and b/build/vignette.rds differ diff --git a/inst/CITATION b/inst/CITATION index e30d636..16094c7 100644 --- a/inst/CITATION +++ b/inst/CITATION @@ -9,5 +9,6 @@ bibentry( organization = "Université Bordeaux Montaigne", address = "Pessac, France", note = sprintf("R package version %s", meta$Version), - url = "https://packages.tesselle.org/aion/" + url = "https://packages.tesselle.org/aion/", + doi = "10.5281/zenodo.8032278" ) diff --git a/inst/doc/aion.html b/inst/doc/aion.html index 14e350a..bca3b34 100644 --- a/inst/doc/aion.html +++ b/inst/doc/aion.html @@ -12,7 +12,7 @@ - + Introduction to aion @@ -362,7 +362,7 @@

Introduction to aion

N. Frerebeau

-

2023-06-12

+

2023-08-22

diff --git a/inst/doc/bibliography.html b/inst/doc/bibliography.html index 173f487..7918bef 100644 --- a/inst/doc/bibliography.html +++ b/inst/doc/bibliography.html @@ -11,7 +11,7 @@ - + Bibliography @@ -261,7 +261,7 @@

Bibliography

Comprehensive list of references cited in the package

-

2023-06-12

+

2023-08-22

diff --git a/inst/doc/extending.html b/inst/doc/extending.html index 4c0ee5e..2214668 100644 --- a/inst/doc/extending.html +++ b/inst/doc/extending.html @@ -12,7 +12,7 @@ - + Extending aion @@ -362,7 +362,7 @@

Extending aion

N. Frerebeau

-

2023-06-12

+

2023-08-22

diff --git a/man/aion-package.Rd b/man/aion-package.Rd index 1e18d20..d963e47 100644 --- a/man/aion-package.Rd +++ b/man/aion-package.Rd @@ -15,8 +15,9 @@ A toolkit for archaeological time series. This package provides a system of clas \tabular{ll}{ \strong{Package:} \tab aion \cr \strong{Type:} \tab Package \cr -\strong{Version:} \tab 1.0.0 \cr +\strong{Version:} \tab 1.0.1 \cr \strong{License:} \tab GPL-3 \cr +\strong{Zenodo:} \tab \doi{10.5281/zenodo.8032278} \cr } } \section{Package options}{ diff --git a/man/series.Rd b/man/series.Rd index 228edad..d759f72 100644 --- a/man/series.Rd +++ b/man/series.Rd @@ -34,8 +34,8 @@ series(object, time, calendar, ...) } \arguments{ \item{object}{A \code{\link{numeric}} \code{vector}, \code{matrix} or \code{array} of the observed -time-series values. -A \code{\link{data.frame}} will be coerced to a \code{numeric} \code{matrix} via \code{\link[=data.matrix]{data.matrix()}}.} +time-series values. A \code{\link{data.frame}} will be coerced to a \code{numeric} \code{matrix} +via \code{\link[=data.matrix]{data.matrix()}}.} \item{time}{A \code{\link{numeric}} vector of (decimal) years or a \code{\linkS4class{RataDie}} object (see \code{\link[=fixed]{fixed()}}).}