Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Import datasets and documentation from epidatasets #520

Merged
merged 40 commits into from
Oct 15, 2024
Merged
Show file tree
Hide file tree
Changes from 36 commits
Commits
Show all changes
40 commits
Select commit Hold shift + click to select a range
2c5d29a
import epidatasets
nmdefries Aug 30, 2024
3f4a07d
remove locally-generated data
nmdefries Aug 30, 2024
d9197a1
reexport data from epidatasets
nmdefries Aug 30, 2024
6a75553
jhu_csse_daily_subset -> cases_deaths_subset
nmdefries Aug 30, 2024
d7195bd
jhu_csse_county_level_subset -> covid_incidence_county_subset
nmdefries Aug 30, 2024
d805c04
incidence_num_outlier_example -> covid_incidence_outliers
nmdefries Aug 30, 2024
aedce88
cases in intro vignette -> jhu_confirmed_cumulative_num
nmdefries Aug 30, 2024
93ee50d
switch all vignettes to visibly loading prepared data; provide API ca…
nmdefries Aug 30, 2024
9066ef5
can't use data() to fetch reexports in vignettes
nmdefries Sep 5, 2024
a7d2f77
document delayassign-ed archive_cases_dv_subset
nmdefries Sep 5, 2024
0ba4aaa
rcmdcheck cleanup
nmdefries Sep 5, 2024
e2a5da1
don't export _dt underlying archive example data
nmdefries Sep 5, 2024
f135010
reexport archive and covid_case_death_rates
nmdefries Sep 6, 2024
5e8ba56
note as_of in data docs; use as_of in vignette data fetch code
nmdefries Sep 6, 2024
171e984
remove data.R tests
nmdefries Sep 6, 2024
012795e
use delayed assignment for datasets
nmdefries Sep 16, 2024
ad225b2
linting
nmdefries Sep 16, 2024
d88d44d
style: styler (GHA)
nmdefries Sep 16, 2024
779ec2a
use cases_deaths_subset instead of covid_case_death_rates
nmdefries Sep 17, 2024
5518c67
remove epidatr calls in vignettes; dontrun failing example code
nmdefries Oct 1, 2024
ef8dc27
redocument; attribute jhu and delphi for data
nmdefries Oct 2, 2024
e04f5a7
load covidcast in aggregation vignette
nmdefries Oct 2, 2024
b6a7d58
Merge branch 'dev' into ndefries/epidatasets-migration
nmdefries Oct 2, 2024
42d8d95
style: styler (GHA)
nmdefries Oct 2, 2024
a2c3cf0
docs: document (GHA)
nmdefries Oct 2, 2024
0e6798f
import glue
nmdefries Oct 2, 2024
47bf883
remove trailing paren
nmdefries Oct 2, 2024
50af59b
news and version
nmdefries Oct 2, 2024
040fadf
Merge branch 'dev' into ndefries/epidatasets-migration
nmdefries Oct 2, 2024
cbab352
docs: document (GHA)
nmdefries Oct 2, 2024
888bb57
Re-export editing pass + don't re-export cumulative death data
brookslogan Oct 3, 2024
dfbed13
style: styler (GHA)
brookslogan Oct 3, 2024
e0cfdb0
Fix _pkgdown.yml
brookslogan Oct 3, 2024
a7a34e6
switch correlation vignette data to one with all states
nmdefries Oct 4, 2024
38b8fb0
Merge branch 'dev' into ndefries/epidatasets-migration
nmdefries Oct 4, 2024
9b33b09
import readr in aggregation vignette
nmdefries Oct 7, 2024
fc3650d
Note some other breaking changes in epidatasets migration
brookslogan Oct 14, 2024
a32166b
Address some no-visible-binding CHECKS
brookslogan Oct 14, 2024
7df79ba
Remove now-unnecessary `library(covidcast)`
brookslogan Oct 14, 2024
c9d1877
Add missing topic to _pkgdown.yml
brookslogan Oct 15, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 10 additions & 3 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Type: Package
Package: epiprocess
Title: Tools for basic signal processing in epidemiology
Version: 0.9.4
Version: 0.9.5
Authors@R: c(
person("Jacob", "Bien", role = "ctb"),
person("Logan", "Brooks", , "[email protected]", role = c("aut", "cre")),
Expand All @@ -20,7 +20,13 @@ Authors@R: c(
person("Hadley", "Wickham", role = "ctb",
comment = "Author of included rlang fragments"),
person("Posit", role = "cph",
comment = "Copyright holder of included rlang fragments")
comment = "Copyright holder of included rlang fragments"),
person("Johns Hopkins University Center for Systems Science and Engineering", role = "dtc",
comment = "Owner of COVID-19 cases and deaths data from the COVID-19 Data Repository"),
person("Johns Hopkins University", role = "cph",
comment = "Copyright holder of COVID-19 cases and deaths data from the COVID-19 Data Repository"),
person("Carnegie Mellon University Delphi Group", role = "dtc",
comment = "Owner of claims-based CLI data from the Delphi Epidata API")
)
Description: This package introduces a common data structure for
epidemiological data reported by location and time, provides another
Expand All @@ -36,6 +42,7 @@ Imports:
cli,
data.table,
dplyr (>= 1.1.0),
epidatasets,
genlasso,
ggplot2,
glue,
Expand Down Expand Up @@ -64,6 +71,7 @@ Suggests:
VignetteBuilder:
knitr
Remotes:
cmu-delphi/epidatasets,
cmu-delphi/epidatr,
glmgen/genlasso,
reconverse/outbreaks
Expand All @@ -78,7 +86,6 @@ Collate:
'archive.R'
'autoplot.R'
'correlation.R'
'data.R'
'epi_df.R'
'epi_df_forbidden_methods.R'
'epiprocess.R'
Expand Down
5 changes: 5 additions & 0 deletions NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,12 @@ export(as_epi_archive)
export(as_epi_df)
export(as_tsibble)
export(autoplot)
export(cases_deaths_subset)
export(clone)
export(complete)
export(covid_case_death_rates_extended)
export(covid_incidence_county_subset)
export(covid_incidence_outliers)
export(detect_outlr)
export(detect_outlr_rm)
export(detect_outlr_stl)
Expand Down Expand Up @@ -100,6 +104,7 @@ export(ungroup)
export(unnest)
export(validate_epi_archive)
export(version_column_names)
import(epidatasets)
importFrom(checkmate,anyInfinite)
importFrom(checkmate,anyMissing)
importFrom(checkmate,assert)
Expand Down
7 changes: 7 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,13 @@ Pre-1.0.0 numbering scheme: 0.x will indicate releases, while 0.x.y will indicat

## Breaking changes

- Moved example datasets from being hosted in the package to being reexported
from the `epidatasets` package. The datasets can no longer be loaded with
`data()` but can be accessed with `epiprocess::` or, after loading the package,
just the name of the dataset (#520).

## Bug fixes

- Removed `.window_size = 1` default from `epi_slide_{mean,sum,opt}`; this
argument is now mandatory, and should nearly always be greater than 1 except
for testing purposes.
Expand Down
10 changes: 5 additions & 5 deletions R/autoplot.R
Original file line number Diff line number Diff line change
Expand Up @@ -26,19 +26,19 @@
#' @export
#'
#' @examples
#' autoplot(jhu_csse_daily_subset, cases, death_rate_7d_av)
#' autoplot(jhu_csse_daily_subset, case_rate_7d_av, .facet_by = "geo_value")
#' autoplot(jhu_csse_daily_subset, case_rate_7d_av,
#' autoplot(cases_deaths_subset, cases, death_rate_7d_av)
#' autoplot(cases_deaths_subset, case_rate_7d_av, .facet_by = "geo_value")
#' autoplot(cases_deaths_subset, case_rate_7d_av,
#' .color_by = "none",
#' .facet_by = "geo_value"
#' )
#' autoplot(jhu_csse_daily_subset, case_rate_7d_av,
#' autoplot(cases_deaths_subset, case_rate_7d_av,
#' .color_by = "none",
#' .base_color = "red", .facet_by = "geo_value"
#' )
#'
#' # .base_color specification won't have any effect due .color_by default
#' autoplot(jhu_csse_daily_subset, case_rate_7d_av,
#' autoplot(cases_deaths_subset, case_rate_7d_av,
#' .base_color = "red", .facet_by = "geo_value"
#' )
autoplot.epi_df <- function(
Expand Down
8 changes: 4 additions & 4 deletions R/correlation.R
Original file line number Diff line number Diff line change
Expand Up @@ -44,15 +44,15 @@
#'
#' # linear association of case and death rates on any given day
#' epi_cor(
#' x = jhu_csse_daily_subset,
#' x = cases_deaths_subset,
#' var1 = case_rate_7d_av,
#' var2 = death_rate_7d_av,
#' cor_by = "time_value"
#' )
#'
#' # correlation of death rates and lagged case rates
#' epi_cor(
#' x = jhu_csse_daily_subset,
#' x = cases_deaths_subset,
#' var1 = case_rate_7d_av,
#' var2 = death_rate_7d_av,
#' cor_by = time_value,
Expand All @@ -61,15 +61,15 @@
#'
#' # correlation grouped by location
#' epi_cor(
#' x = jhu_csse_daily_subset,
#' x = cases_deaths_subset,
#' var1 = case_rate_7d_av,
#' var2 = death_rate_7d_av,
#' cor_by = geo_value
#' )
#'
#' # correlation grouped by location and incorporates lagged cases rates
#' epi_cor(
#' x = jhu_csse_daily_subset,
#' x = cases_deaths_subset,
#' var1 = case_rate_7d_av,
#' var2 = death_rate_7d_av,
#' cor_by = geo_value,
Expand Down
Loading
Loading