diff --git a/.Rbuildignore b/.Rbuildignore index 8424125..6662fd1 100644 --- a/.Rbuildignore +++ b/.Rbuildignore @@ -1,4 +1,3 @@ -.Rcheck$ ^.Rproj$ ^.Rproj.user ^.gitignore @@ -15,7 +14,6 @@ ^README.md ^README.html ^RAQSAPI.Rproj -^doc$ ^dev$ .out$ .log$ @@ -34,11 +32,18 @@ dev/install_RAQSAPI.R ^.github$ ^.github/workflows/R-CMD-check\.yaml$ ^.Rprofile$ + #Set up hte loocal environment for unit tests tests/testthat/local.R dev/* ^.*\.Rproj$ ^\.Rproj\.user$ codemeta.json -^revdep$ ^LICENSE\.md$ +# Output files from R CMD check +/*.Rcheck/ +# RAQSAPI package files +^.tar.gz +^.zip +^CITATION\.cff$ +^RAQSAPI\.code-workspace$ diff --git a/.github/workflows/R-CMD-check.yaml b/.github/workflows/R-CMD-check.yaml index 968ec10..49a3d77 100644 --- a/.github/workflows/R-CMD-check.yaml +++ b/.github/workflows/R-CMD-check.yaml @@ -2,9 +2,9 @@ # Need help debugging build failures? Start at https://github.com/r-lib/actions#where-to-find-help on: push: - branches: [main, httr2] + branches: [main, httr2, test_github_workflow] pull_request: - branches: [main, httr2] + branches: [main, httr2, test_github_workflow] name: R-CMD-check @@ -26,8 +26,8 @@ jobs: env: GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} - RAQSAPIKEY: ${{ secrets.AQSKEY }} - RAQSAPIUSERNAME: ${{ secrets.AQSUSER }} + RAQSAPIKEY: "${{ secrets.RAQSAPIKEY }}" + RAQSAPIUSERNAME: "${{ secrets.RAQSAPIUSERNAME }}" R_KEEP_PKG_SOURCE: yes steps: diff --git a/.gitignore b/.gitignore index af9cf26..4d471d9 100644 --- a/.gitignore +++ b/.gitignore @@ -46,3 +46,13 @@ dev/contributing.Rmd #Set up hte loocal environment for unit tests tests/testthat/local.R dev/.experimental.R + +# Output files from R CMD check +/*.Rcheck/ +/doc/ +/Meta/ + +# RAQSAPI package files +*.tar.gz +*.zip +RAQSAPI.code-workspace diff --git a/CITATION.cff b/CITATION.cff new file mode 100644 index 0000000..8829566 --- /dev/null +++ b/CITATION.cff @@ -0,0 +1,453 @@ +# ----------------------------------------------------------- +# CITATION file created with {cffr} R package, v0.5.0 +# See also: https://docs.ropensci.org/cffr/ +# ----------------------------------------------------------- + +cff-version: 1.2.0 +message: 'To cite package "RAQSAPI" in publications use:' +type: software +license: MIT +title: 'RAQSAPI: A Simple Interface to the US EPA Air Quality System Data Mart API' +version: 2.0.5 +abstract: Retrieve air monitoring data and associated metadata from the US Environmental + Protection Agency's Air Quality System service using functions. See + for details about the US EPA Data Mart API. +authors: +- family-names: Mccrowey + given-names: Clinton + email: mccrowey.clinton@epa.gov +- family-names: Sharac + given-names: Timothy +- family-names: Mangus + given-names: Nick +- family-names: Jager + given-names: Doug +- family-names: Brown + given-names: Ryan +- family-names: Garver + given-names: Daniel +- family-names: Wells + given-names: Benjamin +- family-names: Brittingham + given-names: Hayley +- family-names: Hollister + given-names: Jeffrey + email: hollister.jeff@epa.gov + orcid: https://orcid.org/0000-0002-9254-9740 +- family-names: Andrews + given-names: Edward + email: edward.s.andrews@wv.gov +preferred-citation: + type: manual + title: A R Interface to the US EPA Air Quality System Data Mart API + authors: + - family-names: Mccrowey + given-names: Clinton + email: mccrowey.clinton@epa.gov + - family-names: Sharac + given-names: Timothy + - family-names: Mangus + given-names: Nick + - family-names: Jager + given-names: Doug + - family-names: Brown + given-names: Ryan + - family-names: Garver + given-names: Daniel + - family-names: Wells + given-names: Benjamin + - family-names: Brittingham + given-names: Hayley + year: '2023' + url: https://cran.r-project.org/package=RAQSAPI +repository: https://CRAN.R-project.org/package=RAQSAPI +repository-code: https://github.com/USEPA/RAQSAPI +url: https://github.com/USEPA/RAQSAPI +contact: +- family-names: Mccrowey + given-names: Clinton + email: mccrowey.clinton@epa.gov +keywords: +- United State Environmental Protection Agency +- Environmental-data-retrieval +- Air-Quality-System +- AQS-Datamart +- Air-monitoring +- Environmental-monitoring +- airmonitoring +- aqs +- datamart +- environmental-data-retrieval +- environmental-monitoring +- r03 +- rpackage +- rprogramming +- usepa +references: +- type: software + title: 'R: A Language and Environment for Statistical Computing' + notes: Depends + url: https://www.R-project.org/ + authors: + - name: R Core Team + location: + name: Vienna, Austria + year: '2023' + institution: + name: R Foundation for Statistical Computing + version: '>= 4.0.0' +- type: software + title: dplyr + abstract: 'dplyr: A Grammar of Data Manipulation' + notes: Imports + url: https://dplyr.tidyverse.org + repository: https://CRAN.R-project.org/package=dplyr + authors: + - family-names: Wickham + given-names: Hadley + email: hadley@posit.co + orcid: https://orcid.org/0000-0003-4757-117X + - family-names: François + given-names: Romain + orcid: https://orcid.org/0000-0002-2444-4226 + - family-names: Henry + given-names: Lionel + - family-names: Müller + given-names: Kirill + orcid: https://orcid.org/0000-0002-1416-3412 + - family-names: Vaughan + given-names: Davis + email: davis@posit.co + orcid: https://orcid.org/0000-0003-4777-038X + year: '2023' +- type: software + title: glue + abstract: 'glue: Interpreted String Literals' + notes: Imports + url: https://glue.tidyverse.org/ + repository: https://CRAN.R-project.org/package=glue + authors: + - family-names: Hester + given-names: Jim + orcid: https://orcid.org/0000-0002-2739-7082 + - family-names: Bryan + given-names: Jennifer + email: jenny@rstudio.com + orcid: https://orcid.org/0000-0002-6983-2759 + year: '2023' +- type: software + title: httr2 + abstract: 'httr2: Perform HTTP Requests and Process the Responses' + notes: Imports + url: https://httr2.r-lib.org + repository: https://CRAN.R-project.org/package=httr2 + authors: + - family-names: Wickham + given-names: Hadley + email: hadley@rstudio.com + year: '2023' +- type: software + title: lifecycle + abstract: 'lifecycle: Manage the Life Cycle of your Package Functions' + notes: Imports + url: https://lifecycle.r-lib.org/ + repository: https://CRAN.R-project.org/package=lifecycle + authors: + - family-names: Henry + given-names: Lionel + email: lionel@posit.co + - family-names: Wickham + given-names: Hadley + email: hadley@posit.co + orcid: https://orcid.org/0000-0003-4757-117X + year: '2023' +- type: software + title: lubridate + abstract: 'lubridate: Make Dealing with Dates a Little Easier' + notes: Imports + url: https://lubridate.tidyverse.org + repository: https://CRAN.R-project.org/package=lubridate + authors: + - family-names: Spinu + given-names: Vitalie + email: spinuvit@gmail.com + - family-names: Grolemund + given-names: Garrett + - family-names: Wickham + given-names: Hadley + year: '2023' +- type: software + title: magrittr + abstract: 'magrittr: A Forward-Pipe Operator for R' + notes: Imports + url: https://magrittr.tidyverse.org + repository: https://CRAN.R-project.org/package=magrittr + authors: + - family-names: Bache + given-names: Stefan Milton + email: stefan@stefanbache.dk + - family-names: Wickham + given-names: Hadley + email: hadley@rstudio.com + year: '2023' +- type: software + title: purrr + abstract: 'purrr: Functional Programming Tools' + notes: Imports + url: https://purrr.tidyverse.org/ + repository: https://CRAN.R-project.org/package=purrr + authors: + - family-names: Wickham + given-names: Hadley + email: hadley@rstudio.com + orcid: https://orcid.org/0000-0003-4757-117X + - family-names: Henry + given-names: Lionel + email: lionel@rstudio.com + year: '2023' +- type: software + title: rlang + abstract: 'rlang: Functions for Base Types and Core R and ''Tidyverse'' Features' + notes: Imports + url: https://rlang.r-lib.org + repository: https://CRAN.R-project.org/package=rlang + authors: + - family-names: Henry + given-names: Lionel + email: lionel@posit.co + - family-names: Wickham + given-names: Hadley + email: hadley@posit.co + year: '2023' +- type: software + title: stringr + abstract: 'stringr: Simple, Consistent Wrappers for Common String Operations' + notes: Imports + url: https://stringr.tidyverse.org + repository: https://CRAN.R-project.org/package=stringr + authors: + - family-names: Wickham + given-names: Hadley + email: hadley@posit.co + year: '2023' +- type: software + title: tibble + abstract: 'tibble: Simple Data Frames' + notes: Imports + url: https://tibble.tidyverse.org/ + repository: https://CRAN.R-project.org/package=tibble + authors: + - family-names: Müller + given-names: Kirill + email: kirill@cynkra.com + orcid: https://orcid.org/0000-0002-1416-3412 + - family-names: Wickham + given-names: Hadley + email: hadley@rstudio.com + year: '2023' +- type: software + title: covr + abstract: 'covr: Test Coverage for Packages' + notes: Suggests + url: https://covr.r-lib.org + repository: https://CRAN.R-project.org/package=covr + authors: + - family-names: Hester + given-names: Jim + email: james.f.hester@gmail.com + year: '2023' +- type: software + title: devtools + abstract: 'devtools: Tools to Make Developing R Packages Easier' + notes: Suggests + url: https://devtools.r-lib.org/ + repository: https://CRAN.R-project.org/package=devtools + authors: + - family-names: Wickham + given-names: Hadley + - family-names: Hester + given-names: Jim + - family-names: Chang + given-names: Winston + - family-names: Bryan + given-names: Jennifer + email: jenny@rstudio.com + orcid: https://orcid.org/0000-0002-6983-2759 + year: '2023' +- type: software + title: keyring + abstract: 'keyring: Access the System Credential Store from R' + notes: Suggests + url: https://keyring.r-lib.org/ + repository: https://CRAN.R-project.org/package=keyring + authors: + - family-names: Csárdi + given-names: Gábor + email: csardi.gabor@gmail.com + year: '2023' +- type: software + title: knitr + abstract: 'knitr: A General-Purpose Package for Dynamic Report Generation in R' + notes: Suggests + url: https://yihui.org/knitr/ + repository: https://CRAN.R-project.org/package=knitr + authors: + - family-names: Xie + given-names: Yihui + email: xie@yihui.name + orcid: https://orcid.org/0000-0003-0645-5666 + year: '2023' +- type: software + title: markdown + abstract: 'markdown: Render Markdown with ''commonmark''' + notes: Suggests + url: https://github.com/rstudio/markdown + repository: https://CRAN.R-project.org/package=markdown + authors: + - family-names: Xie + given-names: Yihui + email: xie@yihui.name + orcid: https://orcid.org/0000-0003-0645-5666 + - family-names: Allaire + given-names: JJ + - family-names: Horner + given-names: Jeffrey + year: '2023' +- type: software + title: rmarkdown + abstract: 'rmarkdown: Dynamic Documents for R' + notes: Suggests + url: https://pkgs.rstudio.com/rmarkdown/ + repository: https://CRAN.R-project.org/package=rmarkdown + authors: + - family-names: Allaire + given-names: JJ + email: jj@posit.co + - family-names: Xie + given-names: Yihui + email: xie@yihui.name + orcid: https://orcid.org/0000-0003-0645-5666 + - family-names: Dervieux + given-names: Christophe + email: cderv@posit.co + orcid: https://orcid.org/0000-0003-4474-2498 + - family-names: McPherson + given-names: Jonathan + email: jonathan@posit.co + - family-names: Luraschi + given-names: Javier + - family-names: Ushey + given-names: Kevin + email: kevin@posit.co + - family-names: Atkins + given-names: Aron + email: aron@posit.co + - family-names: Wickham + given-names: Hadley + email: hadley@posit.co + - family-names: Cheng + given-names: Joe + email: joe@posit.co + - family-names: Chang + given-names: Winston + email: winston@posit.co + - family-names: Iannone + given-names: Richard + email: rich@posit.co + orcid: https://orcid.org/0000-0003-3925-190X + year: '2023' +- type: software + title: roxygen2 + abstract: 'roxygen2: In-Line Documentation for R' + notes: Suggests + url: https://roxygen2.r-lib.org/ + repository: https://CRAN.R-project.org/package=roxygen2 + authors: + - family-names: Wickham + given-names: Hadley + email: hadley@rstudio.com + orcid: https://orcid.org/0000-0003-4757-117X + - family-names: Danenberg + given-names: Peter + email: pcd@roxygen.org + - family-names: Csárdi + given-names: Gábor + email: csardi.gabor@gmail.com + - family-names: Eugster + given-names: Manuel + year: '2023' +- type: software + title: spelling + abstract: 'spelling: Tools for Spell Checking in R' + notes: Suggests + url: https://docs.ropensci.org/spelling/ + repository: https://CRAN.R-project.org/package=spelling + authors: + - family-names: Ooms + given-names: Jeroen + email: jeroen@berkeley.edu + orcid: https://orcid.org/0000-0002-4035-0289 + - family-names: Hester + given-names: Jim + email: james.hester@rstudio.com + year: '2023' +- type: software + title: testthat + abstract: 'testthat: Unit Testing for R' + notes: Suggests + url: https://testthat.r-lib.org + repository: https://CRAN.R-project.org/package=testthat + authors: + - family-names: Wickham + given-names: Hadley + email: hadley@posit.co + year: '2023' + version: '>= 3.0.0' +- type: software + title: usethis + abstract: 'usethis: Automate Package and Project Setup' + notes: Suggests + url: https://usethis.r-lib.org + repository: https://CRAN.R-project.org/package=usethis + authors: + - family-names: Wickham + given-names: Hadley + email: hadley@posit.co + orcid: https://orcid.org/0000-0003-4757-117X + - family-names: Bryan + given-names: Jennifer + email: jenny@posit.co + orcid: https://orcid.org/0000-0002-6983-2759 + - family-names: Barrett + given-names: Malcolm + email: malcolmbarrett@gmail.com + orcid: https://orcid.org/0000-0003-0299-5825 + - family-names: Teucher + given-names: Andy + email: andy.teucher@posit.co + orcid: https://orcid.org/0000-0002-7840-692X + year: '2023' +- type: software + title: withr + abstract: 'withr: Run Code ''With'' Temporarily Modified Global State' + notes: Suggests + url: https://withr.r-lib.org + repository: https://CRAN.R-project.org/package=withr + authors: + - family-names: Hester + given-names: Jim + - family-names: Henry + given-names: Lionel + email: lionel@posit.co + - family-names: Müller + given-names: Kirill + email: krlmlr+r@mailbox.org + - family-names: Ushey + given-names: Kevin + email: kevinushey@gmail.com + - family-names: Wickham + given-names: Hadley + email: hadley@rstudio.com + - family-names: Chang + given-names: Winston + year: '2023' diff --git a/DESCRIPTION b/DESCRIPTION index 815e15d..2ab9ed2 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -45,8 +45,8 @@ Authors@R: c(person(given="Clinton", family="Mccrowey", comment = "West Virginia Department of Environmental Protection, Division of Air Quality" ) ) -URL: , - +URL: https://github.com/USEPA/RAQSAPI/, + https://aqs.epa.gov/aqsweb/documents/data_api.html BugReports: https://github.com/USEPA/RAQSAPI/issues Depends: R (>= 4.0.0) Imports: @@ -63,7 +63,6 @@ Imports: Suggests: covr, devtools, - goodpractice, keyring, knitr, markdown, @@ -73,8 +72,9 @@ Suggests: testthat (>= 3.0.0), usethis, withr -SystemRequirements: package manual requires pandoc (>= 1.14) http://pandoc.org -RoxygenNote: 7.2.3 +SystemRequirements: package manual and Vignettes require pandoc + (>= 1.14) http://pandoc.org) +RoxygenNote: 7.3.1 VignetteBuilder: knitr BuildVignettes: true ByteCompile: true diff --git a/MD5 b/MD5 index 42aae67..a4be22a 100644 --- a/MD5 +++ b/MD5 @@ -1,16 +1,16 @@ -d3a7f7cc6aca27a043309d5bf9f32edc *codemeta.json -a4f38bdcd1e2b228600cb6e693648a12 *cran-comments.md -a4f38bdcd1e2b228600cb6e693648a12 *cran-comments.Rmd -8fe7ddfb9b852c041024d63250b69e7d *DESCRIPTION +3fe0b2d4c41b6a7ddea1fcc2dc0742a0 *CITATION.cff +f4ff2345ea66f98028bea8e07bb9b6fa *codemeta.json +6e5839d0c24939143566d26d7f427fce *cran-comments.md +6e5839d0c24939143566d26d7f427fce *cran-comments.Rmd +8d3b9fa84140908686c8837fa1056041 *DESCRIPTION 1dc95961c4c280f8645a65d15662725f *dev/contributing.md 4fc13def6ec5d889261f1f22a13ba542 *dev/contributing.Rmd 74e297a0dc0b508ed18e3821264958d0 *dev/countlinesofcode.R -754314a32bcdbb1835d90b0f59339b60 *dev/hexsticker.R -9088f302621cd20a9c66012367b9c2a2 *dev/install_RAQSAPI.R +ed21caa73378a9cdf8de4df12cc848c0 *dev/install_RAQSAPI.R 3c41777493d242206848842b6ba74fde *inst/CITATION 3df907b50c4f00bc26ee6d988e0c849f *inst/codecov.yml dd65d70b425fb86f7c8b6d8841a837d8 *inst/schemaorg.json -44650d3802ce6c4eccbbfc02684e51a2 *inst/WORDLIST +c249300fd572e8b3c57b98e3d3c8745b *inst/WORDLIST e5b82cf7f3c21891bc0643f662a3f1ba *LICENSE 9b3dc9e54281bcaa0a530371869f506c *LICENSE.md e7ec2b281fcab3d1b34b26031438438a *man/aqs_annualsummary_by_box.Rd @@ -91,7 +91,7 @@ a8f79ece8b275d2f60fc09a58239e661 *man/aqs_quarterlysummary_by_site.Rd 4232385c24cb5041c7ad57ec9279a798 *man/aqs_sampledata_by_county.Rd d6bccf166ae844172cf9b241c89093e2 *man/aqs_sampledata_by_site.Rd a10c5684e68d35cebb418f849c058609 *man/aqs_sampledata_by_state.Rd -0557bd694ffc18246eda85f4813fc2d1 *man/aqs_sampledurations.Rd +e18bec0d4aa22d14a5c796adc3998d91 *man/aqs_sampledurations.Rd f9d84d9671e9c011e40dcf3567f3aa47 *man/aqs_services_by_box.Rd 9291322a3bd3a17248904a0bfcf32d2f *man/aqs_services_by_cbsa.Rd 9ca1f01ed3c413b5c8cd1f9f2bec9f3d *man/aqs_services_by_county.Rd @@ -106,7 +106,7 @@ fb79be8f8717990d152ad5b23751a339 *man/aqs_states.Rd 47b7cbe49d382aac8348ee5cca982de6 *man/aqs_transactionsample_by_MA.Rd d2237cdfe2355d3365ffb7628e121a3d *man/aqs_transactionsample_by_site.Rd 320d2b475c628672e8fcb2db6c39d512 *man/aqs_transactionsample_by_state.Rd -f15ba2d7370da25a949470e01c852436 *man/deprecated.Rd.Rd +f15ba2d7370da25a949470e01c852436 *man/deprecated.Rd a1cbaf3f328e8d74e747faacf640c7fc *man/figures/lifecycle-archived.svg 6f521fb1819410630e279d1abf88685a *man/figures/lifecycle-defunct.svg 391f696f961e28914508628a7af31b74 *man/figures/lifecycle-deprecated.svg @@ -116,10 +116,9 @@ f41ed996be135fb35afe00641621da61 *man/figures/lifecycle-questioning.svg 306bef67d1c636f209024cf2403846fd *man/figures/lifecycle-soft-deprecated.svg ed42e3fbd7cc30bc6ca8fa9b658e24a8 *man/figures/lifecycle-stable.svg bf2f1ad432ecccee3400afe533404113 *man/figures/lifecycle-superseded.svg -7ce4525010156c02adaf819a8c835134 *man/RAQSAPI.Rd -57d6cc4244ee282e5008f2245cbb451f *NAMESPACE -904839971aff979c1716322c7d8bcdff *NEWS.md -c224e1b2fd7afe09802d6b7586fd4097 *R/AQSAPI_helperfunctions.R +14dea302d2901ec5384577249f059654 *man/RAQSAPI.Rd +eef9bd75f39b496fcfd63a36be7fb5a8 *NAMESPACE +68f4c551ed9b572bb7c6a3ab9228b75c *R/AQSAPI_helperfunctions.R a3558975d0256839b174ab7868833075 *R/bybox.R bd8b36cc7325d4fc8b8ed894f0046678 *R/bycbsa.R 253ea551f88c65c1c49feff3cb33f552 *R/bycounty.R @@ -127,284 +126,15 @@ d82b1ff8ee144afca1879e5b8dc58840 *R/byma.R 75cbb841598edc4dc4857950c6e4b0b5 *R/bypqao.R 6acae078848030131e628154099e5f53 *R/bysite.R 2e6e59d801dc3b6bd5e415ada7268469 *R/bystate.R -8198ed65b99926d0ed9b07c49a1bf8e2 *R/deprecated.R -87275ab3c5bd1af63ecfbd835ea8f53b *R/RAQSAPI-package.R -8bf50a551dbb3798f968436f95e3c343 *R/RAQSAPIlistfunctions.R +5b01d32e630b9b68041a139e4ae6f748 *R/deprecated.R +6fb9bc5a422698bef6bdd147006c0439 *R/RAQSAPI-package.R +cebed24e7ab755d8642a74c7e9b80fd5 *R/RAQSAPIlistfunctions.R e6e3b87e48f4403642382987b0f40714 *R/setupfunctions.R 6e659bb3bbf313dc819d4c029f0b22d0 *R/zzz.R -8f51fe5ddf897afb20925542060627f7 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/build/stage23.rdb -12aced1f7b2dd6f0d2c8054e24271e0b *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/build/vignette.rds -f8f0232f6b4566f337a42b9d5815aebf *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/DESCRIPTION -3c41777493d242206848842b6ba74fde *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/CITATION -e20df979617a9f8c55da8b1506da4078 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/codecov.yml -e4d3a123b14a89ab800c5e143d19da61 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/Acknowledgements.html -49025d261826350f3050e677eab9dbac *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/Acknowledgements.Rmd -de323c3deb36e066a7583c5b756ae49b *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/EPA_Disclaimer.html -a79d926b2ab509e6a9e575539b205280 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/EPA_Disclaimer.Rmd -f2ae2ad47d08797f778439b01a3a9417 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/InstallandSetup.html -69224454907b49f3de5fcf3527a3ad3f *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/InstallandSetup.Rmd -8cefad4a9367dfd29b6622140d4f6973 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/Intro.html -a629c5720b68a384451709002c95a499 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/Intro.Rmd -bce644f7c50a618fee8429b3655e5fb9 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/RAQSAPIFunctions-Brief.html -1dbae57a3f574ccd77b4d2af2c76e831 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/RAQSAPIFunctions-Brief.Rmd -cc0f370ba9e854f2f15d0ad4711559fe *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/RAQSAPIFunctions-Long.html -298d5dd5fb37b777a3235c0aeb3733bb *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/RAQSAPIFunctions-Long.R -85c580fbdeb29023fb03126654384923 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/RAQSAPIFunctions-Long.Rmd -912519b2b60dc147b4cbb934d0da2588 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/RAQSAPIPurpose.html -ea8eab93de05207476b4c5f91642b478 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/RAQSAPIPurpose.R -b676d49a421ed0b581e2b3269bac31e0 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/RAQSAPIPurpose.Rmd -145f6d07d3e1b62d2109d2b42885ef35 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/RAQSAPIusagetipsandprecautions.html -629b81e7f6056a9411e2ce16e4dfc5c8 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/RAQSAPIusagetipsandprecautions.Rmd -9f28ab420df5c1cf26c369678b33910d *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/RAQSAPIvignette.html -f699388355cf6bf668200349774ad51c *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/RAQSAPIvignette.R -cc873a7101715766a6057c2cbb59609d *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/RAQSAPIvignette.Rmd -252489c90ef30ae2026cb9a50fc6ad35 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/TimelinessofAQSData.html -5d3445414bf02629a8a10b6dc05c47e7 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/TimelinessofAQSData.Rmd -4a6f61ae81515d8b770f30841ef17fc1 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/Troubleshooting.html -1fee66dbee4d04b47a0b7747ea282a5b *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/Troubleshooting.Rmd -88eec7c1fd07d51e6bd2007f68098b15 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/UsingRAQSAPI.html -969189538d2ec6a0e10ea6d7350ab612 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/doc/UsingRAQSAPI.Rmd -dd65d70b425fb86f7c8b6d8841a837d8 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/schemaorg.json -44650d3802ce6c4eccbbfc02684e51a2 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/WORDLIST -bb220ff3f4bcd893aa398e4c8c8cae65 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_annualsummary_by_box.Rd -c573c6798acca4ff4685ecd719ec2bb8 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_annualsummary_by_cbsa.Rd -83ae0d7a99af595a6c7bc6434c0a150c *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_annualsummary_by_county.Rd -f08db27eded1c54408da341540c26cea *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_annualsummary_by_site.Rd -9787dae337bb0fef010e7a1c53222bca *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_annualsummary_by_state.Rd -c902f26fabddfa0a6c5712967c8459a8 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_cbsas.Rd -11146e4177f407a62384a26c4e46e24d *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_classes.Rd -635b9f68a7502c2fe986d1c960b1c6aa *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_counties_by_state.Rd -0284a9ae6039270e4df20f55d70795d3 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_credentials.Rd -ed4aa24a77ccec72bafd04e13da9a633 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_dailysummary_by_box.Rd -e88ab16e7a5d2fb2b97321e19385cb73 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_dailysummary_by_cbsa.Rd -a9bd30bd63cb0d87950a29dacd09b863 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_dailysummary_by_county.Rd -e1d0feac3f5dbd4bd00a0f22d9e0f29b *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_dailysummary_by_site.Rd -9c6d1be4343c66028c05f79825e99f1d *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_dailysummary_by_state.Rd -7f8cd4e7da4cd163bf26e7a42ab7f0dd *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_fields_by_service.Rd -cb7e75393a961f4e24295c6fe41cd7ca *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_isavailable.Rd -9dc10c75742f0ae7c5ab84491b97ab9e *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_knownissues.Rd -1c54447803b06ad16803869121215bba *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_mas.Rd -5dd208dfb069b56487671b3914c25b87 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_metadata_service.Rd -e0839a2a0cf675efca6d8c28cd08969a *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_monitors_by_box.Rd -1342361e95bfabe2446c540972831fd7 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_monitors_by_cbsa.Rd -d4bb1ac4b1d1d03e018070e0dc22707b *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_monitors_by_county.Rd -ce6df8130162058c316f6948df11952b *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_monitors_by_site.Rd -fbcb7b0e9cc9fff0f35ca06870685bb2 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_monitors_by_state.Rd -92d9f7d8687715b6326f576877613e3f *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_parameters_by_class.Rd -ea076f228e88f88cd02ac4085f5f5f9c *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_pqaos.Rd -35956c4b388bf52a5f47439e2da30a3c *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceeval_by_county.Rd -8d3c09175b73cdf5bebbeb45c0fe6192 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceeval_by_MA.Rd -d33768a55f365072c3e3dee9e858b815 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceeval_by_pqao.Rd -e5ef33a9ba316d06c9723b4e83be9be4 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceeval_by_site.Rd -c273c50e3ee2426e9010eefdf66602e8 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceeval_by_state.Rd -20f133f3b85058cf576efa679a4581e7 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceevaltransaction_by_county.Rd -512a8426dc86b61f6de03db7f2984b2a *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceevaltransaction_by_MA.Rd -7a1880e0f79e808cf6dea9a3000d79b7 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceevaltransaction_by_pqao.Rd -0a422f05de4fca8f10b3d9a33bdbcb83 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceevaltransaction_by_site.Rd -442ad40c59960725670c9a54530014fe *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceevaltransaction_by_state.Rd -08c77dc2b18c4c3c729f4eace49b2d33 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_blanks_by_county.Rd -35efc7bb2119310f4ee13a3086429e07 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_blanks_by_MA.Rd -5badb7a29dd665bbdc5e054213aff75e *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_blanks_by_pqao.Rd -822b2cecf1083dc1830a9847226beb5e *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_blanks_by_site.Rd -9ed6bea911ff7034dfbb4416a1a354de *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_blanks_by_state.Rd -66c193970593756529011f7859519856 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_collocated_assessments_by_county.Rd -ac7c11700cccee1e122ee096d6eaef18 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_collocated_assessments_by_MA.Rd -02d8c754a69ec086a78d532548f2d299 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_collocated_assessments_by_pqao.Rd -b12509db8c4dac180f964362eebb7060 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_collocated_assessments_by_site.Rd -79616bd31337c718e01d9f061988e93c *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_collocated_assessments_by_state.Rd -97dab4a117408d1e088dc7de46095fc5 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateaudit_by_county.Rd -f182f2d7e8d8dc9001478f34eff53e3e *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateaudit_by_MA.Rd -28065194126899e73db92cc87815135c *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateaudit_by_pqao.Rd -07ba9d9be387b0e574243789f6f3ba03 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateaudit_by_site.Rd -ac81b00199d6f992a6d8d54e9585a606 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateaudit_by_state.Rd -7b8f9aa2d83cbd1b9613d098f5be21a6 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateverification_by_county.Rd -a6edf6900c0776e2f0388a77123b7883 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateverification_by_MA.Rd -f3d030fa171ca3807fcfd6da3efc5b87 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateverification_by_pqao.Rd -487f3f6780db3abaee35613a6296837c *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateverification_by_site.Rd -870cfb752059c2363134f5043311d7e8 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateverification_by_state.Rd -54a3e89136e58b5c9be307b456e4c098 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_one_point_qc_by_county.Rd -ab0222ba19fec3f73d3e5138d1885fa7 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_one_point_qc_by_MA.Rd -846a89e4af9c0c0e4d2b0bb923d3c5e9 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_one_point_qc_by_pqao.Rd -573988e51ec1b91182e132dda32b6a2c *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_one_point_qc_by_site.Rd -dee3fbfb48fae4536d9975271f9be4e8 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_one_point_qc_by_state.Rd -94bc713c1a7eab6e6729af4e2a6f3cfd *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_pep_audit_by_county.Rd -068f77df379848df4604ab77ebaf4b68 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_pep_audit_by_MA.Rd -d46ca1fc46943740de7baa971356c004 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_pep_audit_by_pqao.Rd -67d9a5bda83c84a2cf14ff0f2ea51ecc *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_pep_audit_by_site.Rd -026eb2e3e5d0ce00921c8ac8829fe09e *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_pep_audit_by_state.Rd -945fe6e74a42cfc211257e6c5f5e7ca7 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_quarterlysummary_by_box.Rd -82fddc7840ae24f9f040ff08d7c6423d *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_quarterlysummary_by_cbsa.Rd -5df0804ce29c18fa576e7099daac482a *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_quarterlysummary_by_county.Rd -8f35870dea3914136de44218963e5199 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_quarterlysummary_by_site.Rd -df82f66b78af737d2d9e180c772b409e *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_quarterlysummary_by_state.Rd -f92e4ebc11fcde5a90eee4b6bba3e92d *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_removeheader.Rd -b3f77634f7bfcc8880835f3b661f3cdc *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_revisionhistory.Rd -4fc8724dfb6626267d7af14b6c9a9718 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sampledata_by_box.Rd -93b75aebaddfa6c32d0318dda74b3545 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sampledata_by_cbsa.Rd -813b7610185a2d005d4977853884c6bb *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sampledata_by_county.Rd -8529539ef5cacae55d7c397d76353610 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sampledata_by_site.Rd -790936a23ea07e6e4352f64b912e7e18 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sampledata_by_state.Rd -8918f1e4ab12ad6d751bf86ef20ff963 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sampledurations.Rd -aef83261096f38ebf2c99612f20b2b9a *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_box.Rd -7f1a7aca904fa8d811ec90aa278e7d16 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_cbsa.Rd -27b4116ca20e9779f112ed03c3ca3a67 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_county.Rd -90f52d167bbcb955641360608e237c5e *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_MA.Rd -479fae9da1baaccf38d95d7c31b05101 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_pqao.Rd -5504e84d1b2fb49ff2229f8378d6d519 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_site.Rd -2b14aa85862521c521bb7200fd5ef3e1 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_state.Rd -c939541fab3e5ef289eca9be9f8eaeee *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sign_up.Rd -0c4ad0c0172e3807839a69740315b8b1 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sites_by_county.Rd -d4e249969b096762b6fb2919819f209b *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_states.Rd -901d85b050efd6cbaccbbffb114c29a9 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_transactionsample_by_county.Rd -153a0957483467a73cc2ea3d81cc66b7 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_transactionsample_by_MA.Rd -3609a3c6a63209e2ad160f09da3124ba *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_transactionsample_by_site.Rd -9ddf5a536ea48e691d162a9444388119 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_transactionsample_by_state.Rd -34bc825920e9617d287d3b0f3726aca5 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/deprecated.Rd.Rd -32e735dca18b1b6247e46c5a9c95f70b *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-archived.svg -926dda7c74d388ae3fd7476122ffa0ba *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-defunct.svg -8b9317939d546a8bd0ae4da30c658f78 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-deprecated.svg -e1c8d33150e179ed17231c575895092b *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-experimental.svg -44654a4153801346834ce7e52a8b5175 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-maturing.svg -4c06af5b86c85bd056c98ba391c3f82e *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-questioning.svg -b299be1b0cc513f05fa0a8f952f76c38 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-soft-deprecated.svg -383d1a195cfb97ae7af9a37a877b88eb *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-stable.svg -6920593141a53e9e05a9d7c6fd393650 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-superseded.svg -59180a647874cd072cc1311797f581f3 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/RAQSAPI.Rd -3fefa6fab6ae613528f4cecf39cfaf8c *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/NAMESPACE -94c65e3824d4fd9ffa90ec73fed63596 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/NEWS.md -a79461f449d190cef2bb420c23befc5f *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/AQSAPI_helperfunctions.R -a3558975d0256839b174ab7868833075 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/bybox.R -bd8b36cc7325d4fc8b8ed894f0046678 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/bycbsa.R -253ea551f88c65c1c49feff3cb33f552 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/bycounty.R -d82b1ff8ee144afca1879e5b8dc58840 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/byma.R -75cbb841598edc4dc4857950c6e4b0b5 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/bypqao.R -6acae078848030131e628154099e5f53 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/bysite.R -2e6e59d801dc3b6bd5e415ada7268469 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/bystate.R -8198ed65b99926d0ed9b07c49a1bf8e2 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/deprecated.R -d7ceafa78f5ba2098f567b9c9150da20 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/RAQSAPI-package.R -c9fd9ac3f73645262f4c6665c370a9a8 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/RAQSAPIlistfunctions.R -443b6c1736f4b067a7c58b498a3ff5b1 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/setupfunctions.R -6e659bb3bbf313dc819d4c029f0b22d0 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/zzz.R -9566921a96ff55c1a51b6eb898d25884 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/spelling.R -846f989b5f8b7a32fa520e52b4675635 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/test-RAQSAPI.R.blob -cb0e705ce06ab9db6aad083e91041d31 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat.R -56891c92989166a785013a8953da96a3 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/helper.R -37d187be50c130b4e8a8c6d2bb0d9fa5 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-bybox.R -c883634140b22f5fb97c08f909ce377e *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-byCBSA.R -50d37429e9bf99ad5be17e09d92e16e8 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-bycounty.R -19a199f8020db0329fe289a41aa71598 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-byMA.R -f7ea691da1baf266047ed7af4b0c4629 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-bypqao.R -41e407548ac72ec4f41e678d23a566dd *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-bysite.R -051416af24d0386f084eb13a14053ce1 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-bystate.R -014b81fb9c8d2350e1347841f41b24a3 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-helperfunctions.R -8392bc0bfa62b60485a925a2517475a6 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-RAQSAPlistfunctions.R -49025d261826350f3050e677eab9dbac *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/Acknowledgements.Rmd -3fda843a5be3fb9e19364871ff7f8cf6 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/acs-nano.csl -d05384e174a4be63a451f1380a7a58da *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/american-chemical-society.csl -39365075c6f1d3ae375438054d27cb89 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/AQSAPI.bib -a79d926b2ab509e6a9e575539b205280 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/EPA_Disclaimer.Rmd -9f8f6638c5178a9bec62665b4cef5e1d *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/figures/AQS_LOGO.png -ce3de92ce1a1d0851726b5ae8b384b79 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/figures/RAQSAPIhexsticker.png -69224454907b49f3de5fcf3527a3ad3f *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/InstallandSetup.Rmd -a629c5720b68a384451709002c95a499 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/Intro.Rmd -1dbae57a3f574ccd77b4d2af2c76e831 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/RAQSAPIFunctions-Brief.Rmd -85c580fbdeb29023fb03126654384923 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/RAQSAPIFunctions-Long.Rmd -b676d49a421ed0b581e2b3269bac31e0 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/RAQSAPIPurpose.Rmd -629b81e7f6056a9411e2ce16e4dfc5c8 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/RAQSAPIusagetipsandprecautions.Rmd -cc873a7101715766a6057c2cbb59609d *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/RAQSAPIvignette.Rmd -5d3445414bf02629a8a10b6dc05c47e7 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/TimelinessofAQSData.Rmd -1fee66dbee4d04b47a0b7747ea282a5b *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/Troubleshooting.Rmd -969189538d2ec6a0e10ea6d7350ab612 *RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/UsingRAQSAPI.Rmd -f5af51ca5e0b1b8540079b5b2b5ca20e *RAQSAPI.Rcheck/00check.log -07fb36037740409ac121bbd630f28361 *RAQSAPI.Rcheck/00install.out -3a8cb09cc75247f0009062724828672f *RAQSAPI.Rcheck/RAQSAPI-Ex.pdf -535860dffff3ed91e1763704a3ca01da *RAQSAPI.Rcheck/RAQSAPI-Ex.R -d82ce08c7c4030e27b709e94ea9dab47 *RAQSAPI.Rcheck/RAQSAPI-Ex.Rout -567991937fe8be52e3cdaa8074c88dff *RAQSAPI.Rcheck/RAQSAPI-Ex.timings -3c41777493d242206848842b6ba74fde *RAQSAPI.Rcheck/RAQSAPI/CITATION -e20df979617a9f8c55da8b1506da4078 *RAQSAPI.Rcheck/RAQSAPI/codecov.yml -f16588181676c79a2bf49e9379f21e43 *RAQSAPI.Rcheck/RAQSAPI/DESCRIPTION -e4d3a123b14a89ab800c5e143d19da61 *RAQSAPI.Rcheck/RAQSAPI/doc/Acknowledgements.html -49025d261826350f3050e677eab9dbac *RAQSAPI.Rcheck/RAQSAPI/doc/Acknowledgements.Rmd -de323c3deb36e066a7583c5b756ae49b *RAQSAPI.Rcheck/RAQSAPI/doc/EPA_Disclaimer.html -a79d926b2ab509e6a9e575539b205280 *RAQSAPI.Rcheck/RAQSAPI/doc/EPA_Disclaimer.Rmd -a553d4099ca5eaf93be8144a660f2726 *RAQSAPI.Rcheck/RAQSAPI/doc/index.html -f2ae2ad47d08797f778439b01a3a9417 *RAQSAPI.Rcheck/RAQSAPI/doc/InstallandSetup.html -69224454907b49f3de5fcf3527a3ad3f *RAQSAPI.Rcheck/RAQSAPI/doc/InstallandSetup.Rmd -8cefad4a9367dfd29b6622140d4f6973 *RAQSAPI.Rcheck/RAQSAPI/doc/Intro.html -a629c5720b68a384451709002c95a499 *RAQSAPI.Rcheck/RAQSAPI/doc/Intro.Rmd -bce644f7c50a618fee8429b3655e5fb9 *RAQSAPI.Rcheck/RAQSAPI/doc/RAQSAPIFunctions-Brief.html -1dbae57a3f574ccd77b4d2af2c76e831 *RAQSAPI.Rcheck/RAQSAPI/doc/RAQSAPIFunctions-Brief.Rmd -cc0f370ba9e854f2f15d0ad4711559fe *RAQSAPI.Rcheck/RAQSAPI/doc/RAQSAPIFunctions-Long.html -298d5dd5fb37b777a3235c0aeb3733bb *RAQSAPI.Rcheck/RAQSAPI/doc/RAQSAPIFunctions-Long.R -85c580fbdeb29023fb03126654384923 *RAQSAPI.Rcheck/RAQSAPI/doc/RAQSAPIFunctions-Long.Rmd -912519b2b60dc147b4cbb934d0da2588 *RAQSAPI.Rcheck/RAQSAPI/doc/RAQSAPIPurpose.html -ea8eab93de05207476b4c5f91642b478 *RAQSAPI.Rcheck/RAQSAPI/doc/RAQSAPIPurpose.R -b676d49a421ed0b581e2b3269bac31e0 *RAQSAPI.Rcheck/RAQSAPI/doc/RAQSAPIPurpose.Rmd -145f6d07d3e1b62d2109d2b42885ef35 *RAQSAPI.Rcheck/RAQSAPI/doc/RAQSAPIusagetipsandprecautions.html -629b81e7f6056a9411e2ce16e4dfc5c8 *RAQSAPI.Rcheck/RAQSAPI/doc/RAQSAPIusagetipsandprecautions.Rmd -9f28ab420df5c1cf26c369678b33910d *RAQSAPI.Rcheck/RAQSAPI/doc/RAQSAPIvignette.html -f699388355cf6bf668200349774ad51c *RAQSAPI.Rcheck/RAQSAPI/doc/RAQSAPIvignette.R -cc873a7101715766a6057c2cbb59609d *RAQSAPI.Rcheck/RAQSAPI/doc/RAQSAPIvignette.Rmd -252489c90ef30ae2026cb9a50fc6ad35 *RAQSAPI.Rcheck/RAQSAPI/doc/TimelinessofAQSData.html -5d3445414bf02629a8a10b6dc05c47e7 *RAQSAPI.Rcheck/RAQSAPI/doc/TimelinessofAQSData.Rmd -4a6f61ae81515d8b770f30841ef17fc1 *RAQSAPI.Rcheck/RAQSAPI/doc/Troubleshooting.html -1fee66dbee4d04b47a0b7747ea282a5b *RAQSAPI.Rcheck/RAQSAPI/doc/Troubleshooting.Rmd -88eec7c1fd07d51e6bd2007f68098b15 *RAQSAPI.Rcheck/RAQSAPI/doc/UsingRAQSAPI.html -969189538d2ec6a0e10ea6d7350ab612 *RAQSAPI.Rcheck/RAQSAPI/doc/UsingRAQSAPI.Rmd -13e02279a4fd899df229994925f3f670 *RAQSAPI.Rcheck/RAQSAPI/help/aliases.rds -4aaac915765781881d14d007a1d8b8c1 *RAQSAPI.Rcheck/RAQSAPI/help/AnIndex -32e735dca18b1b6247e46c5a9c95f70b *RAQSAPI.Rcheck/RAQSAPI/help/figures/lifecycle-archived.svg -926dda7c74d388ae3fd7476122ffa0ba *RAQSAPI.Rcheck/RAQSAPI/help/figures/lifecycle-defunct.svg -8b9317939d546a8bd0ae4da30c658f78 *RAQSAPI.Rcheck/RAQSAPI/help/figures/lifecycle-deprecated.svg -e1c8d33150e179ed17231c575895092b *RAQSAPI.Rcheck/RAQSAPI/help/figures/lifecycle-experimental.svg -44654a4153801346834ce7e52a8b5175 *RAQSAPI.Rcheck/RAQSAPI/help/figures/lifecycle-maturing.svg -4c06af5b86c85bd056c98ba391c3f82e *RAQSAPI.Rcheck/RAQSAPI/help/figures/lifecycle-questioning.svg -b299be1b0cc513f05fa0a8f952f76c38 *RAQSAPI.Rcheck/RAQSAPI/help/figures/lifecycle-soft-deprecated.svg -383d1a195cfb97ae7af9a37a877b88eb *RAQSAPI.Rcheck/RAQSAPI/help/figures/lifecycle-stable.svg -6920593141a53e9e05a9d7c6fd393650 *RAQSAPI.Rcheck/RAQSAPI/help/figures/lifecycle-superseded.svg -2b2cfe7171ff5a0e9c35214fb2e57424 *RAQSAPI.Rcheck/RAQSAPI/help/paths.rds -984d67a7f6ecf5948c161ce0b1357cb3 *RAQSAPI.Rcheck/RAQSAPI/help/RAQSAPI.rdb -721852fa3fededb2f3daf964ffef6a93 *RAQSAPI.Rcheck/RAQSAPI/help/RAQSAPI.rdx -c57cbd3f9b8dd0562aecb7365e66c19e *RAQSAPI.Rcheck/RAQSAPI/html/00Index.html -a8edcce19d02f8a205d00dc812f36639 *RAQSAPI.Rcheck/RAQSAPI/html/R.css -0fc456b08e2158655be64acd9c89fcdc *RAQSAPI.Rcheck/RAQSAPI/INDEX -f191f333b866ab8dcb201f48270fe190 *RAQSAPI.Rcheck/RAQSAPI/Meta/features.rds -8e6557ca03dc7d7484f868a1e095a51e *RAQSAPI.Rcheck/RAQSAPI/Meta/hsearch.rds -49f5e7f30eb02491d2f179f929310c34 *RAQSAPI.Rcheck/RAQSAPI/Meta/links.rds -66138d6feddc9983e3bdcb273bd65fc6 *RAQSAPI.Rcheck/RAQSAPI/Meta/nsInfo.rds -1d43371d61c6a331d77e30d151c5a115 *RAQSAPI.Rcheck/RAQSAPI/Meta/package.rds -8c3072c9db066c449b550f4de87e0e08 *RAQSAPI.Rcheck/RAQSAPI/Meta/Rd.rds -12aced1f7b2dd6f0d2c8054e24271e0b *RAQSAPI.Rcheck/RAQSAPI/Meta/vignette.rds -3fefa6fab6ae613528f4cecf39cfaf8c *RAQSAPI.Rcheck/RAQSAPI/NAMESPACE -94c65e3824d4fd9ffa90ec73fed63596 *RAQSAPI.Rcheck/RAQSAPI/NEWS.md -c8bda207ff1759df0deb7a69220778a7 *RAQSAPI.Rcheck/RAQSAPI/R/RAQSAPI -36d69a2778a803f2bd6a7ad605ac2dc7 *RAQSAPI.Rcheck/RAQSAPI/R/RAQSAPI.rdb -e77fe25730503615857c360a01f2d17a *RAQSAPI.Rcheck/RAQSAPI/R/RAQSAPI.rdx -dd65d70b425fb86f7c8b6d8841a837d8 *RAQSAPI.Rcheck/RAQSAPI/schemaorg.json -44650d3802ce6c4eccbbfc02684e51a2 *RAQSAPI.Rcheck/RAQSAPI/WORDLIST -9566921a96ff55c1a51b6eb898d25884 *RAQSAPI.Rcheck/tests/spelling.R -0771ddcf9420162924460f9361ff8826 *RAQSAPI.Rcheck/tests/spelling.Rout -f4e07eb82b9a00bae0c0177f4b861511 *RAQSAPI.Rcheck/tests/spelling.Rout.save -4dcaf6e4698de3f0f55bad64d77cde5b *RAQSAPI.Rcheck/tests/startup.Rs -846f989b5f8b7a32fa520e52b4675635 *RAQSAPI.Rcheck/tests/test-RAQSAPI.R.blob -cb0e705ce06ab9db6aad083e91041d31 *RAQSAPI.Rcheck/tests/testthat.R -7fbe889570d84987c39539878f32733a *RAQSAPI.Rcheck/tests/testthat.Rout.fail -56891c92989166a785013a8953da96a3 *RAQSAPI.Rcheck/tests/testthat/helper.R -37d187be50c130b4e8a8c6d2bb0d9fa5 *RAQSAPI.Rcheck/tests/testthat/test-bybox.R -c883634140b22f5fb97c08f909ce377e *RAQSAPI.Rcheck/tests/testthat/test-byCBSA.R -50d37429e9bf99ad5be17e09d92e16e8 *RAQSAPI.Rcheck/tests/testthat/test-bycounty.R -19a199f8020db0329fe289a41aa71598 *RAQSAPI.Rcheck/tests/testthat/test-byMA.R -f7ea691da1baf266047ed7af4b0c4629 *RAQSAPI.Rcheck/tests/testthat/test-bypqao.R -41e407548ac72ec4f41e678d23a566dd *RAQSAPI.Rcheck/tests/testthat/test-bysite.R -051416af24d0386f084eb13a14053ce1 *RAQSAPI.Rcheck/tests/testthat/test-bystate.R -014b81fb9c8d2350e1347841f41b24a3 *RAQSAPI.Rcheck/tests/testthat/test-helperfunctions.R -8392bc0bfa62b60485a925a2517475a6 *RAQSAPI.Rcheck/tests/testthat/test-RAQSAPlistfunctions.R -3e2e78ef3cf7666c3c041ff1b5bec788 *RAQSAPI.Rcheck/tests/testthat/testthat-problems.rds +25bf50b0ec79d01de8b83b7b5801b4ac *RAQSAPI.code-workspace a69de5455537022556f014579766be59 *RAQSAPI.Rproj -cfb9487651a3162cdb4308fb94e30719 *RAQSAPI_2.0.5.tar.gz -210e4ced806d419fa4b5edbb7f3fc2c4 *README.md -10f9e33622104f2df281fb4119a09d36 *README.Rmd +1ef6fd253bab1a2805a72a3777e9eff2 *README.md +9e80ce935498c732a40296459634eb91 *README.Rmd 7ed08f3fb96a77ec01c95c2ad7964250 *revdep/data.sqlite 34952a5944548ea4fc132a9899f8e6ab *revdep/email.yml b7715aa47f5635cfb52f34937886aedf *revdep/library/RAQSAPI/old/askpass/DESCRIPTION @@ -1160,7 +890,7 @@ d6c68f1fe41ced6e98a766a3757313da *revdep/library/RAQSAPI/old/R6/R/R6 9a2c1961edcf2968e9e17856ed21f7ce *revdep/library/RAQSAPI/old/R6/R/R6.rdx 5f3c708ae9a7e3610961d99f3375e60f *revdep/library/RAQSAPI/old/RAQSAPI/CITATION 3df907b50c4f00bc26ee6d988e0c849f *revdep/library/RAQSAPI/old/RAQSAPI/codecov.yml -70e30c409e2788090f475bef50b5022f *revdep/library/RAQSAPI/old/RAQSAPI/DESCRIPTION +ee3578e05ac28d372c75425e260fcecb *revdep/library/RAQSAPI/old/RAQSAPI/DESCRIPTION cf125d5812045cd97093aee831e5c5f5 *revdep/library/RAQSAPI/old/RAQSAPI/doc/Acknowledgements.html 49025d261826350f3050e677eab9dbac *revdep/library/RAQSAPI/old/RAQSAPI/doc/Acknowledgements.Rmd 4b9af1f3b9da96988881ddf1c8d9ee9d *revdep/library/RAQSAPI/old/RAQSAPI/doc/EPA_Disclaimer.html @@ -1588,45 +1318,49 @@ b2d403f29050e86e8efa021931ef8649 *revdep/README.md 9566921a96ff55c1a51b6eb898d25884 *tests/spelling.R 846f989b5f8b7a32fa520e52b4675635 *tests/test-RAQSAPI.R.blob 84732d71bac50c96565c4894a24ecc59 *tests/testthat.R -56891c92989166a785013a8953da96a3 *tests/testthat/helper.R -00b1828926ec94b2537bb2343df723d5 *tests/testthat/local.R -522ea3f8b07f6f4d206ce3fe38f1fbd8 *tests/testthat/test-bybox.R -c883634140b22f5fb97c08f909ce377e *tests/testthat/test-byCBSA.R -50d37429e9bf99ad5be17e09d92e16e8 *tests/testthat/test-bycounty.R -19a199f8020db0329fe289a41aa71598 *tests/testthat/test-byMA.R -f7ea691da1baf266047ed7af4b0c4629 *tests/testthat/test-bypqao.R -41e407548ac72ec4f41e678d23a566dd *tests/testthat/test-bysite.R -051416af24d0386f084eb13a14053ce1 *tests/testthat/test-bystate.R -014b81fb9c8d2350e1347841f41b24a3 *tests/testthat/test-helperfunctions.R -e897203bb026b43141e5bc00dfe3cecd *tests/testthat/test-RAQSAPlistfunctions.R -8ec3157359d9a0fbdf126ed74f399ee1 *vignettes/Acknowledgements.html -49025d261826350f3050e677eab9dbac *vignettes/Acknowledgements.Rmd +89ff48b08754c7fc927acb5b6691bdb1 *tests/testthat/helper.R +2a4012f9bf99ddc63f745bd8e4f845dc *tests/testthat/local.R +309a8c9de99e4f0c0d5c280cb7583dd6 *tests/testthat/test-bybox.R +635cfa38957358d566d9e5d17057df7b *tests/testthat/test-byCBSA.R +61e14922bc589edf93a461a7fe4112cc *tests/testthat/test-bycounty.R +bfcb21038f480e4e9638486f99b45efa *tests/testthat/test-byMA.R +16213bfccb07c9052826097a6b24407c *tests/testthat/test-bypqao.R +257512f5b5e206aa789cf85fd3f616dd *tests/testthat/test-bysite.R +273dda836db047478bc65a94c7e0a05d *tests/testthat/test-bystate.R +9ac730cce5b9a3d7b4b877512bc4de25 *tests/testthat/test-helperfunctions.R +2391f6b331d4bc3e5e9e6a0b73980eba *tests/testthat/test-RAQSAPlistfunctions.R +ce44f2334218eff76881442d89ebdee0 *vignettes/Acknowledgements.html +36ae3777b8fd72d52f8a4a6bfa756207 *vignettes/Acknowledgements.Rmd 22d607e5d49e10047a911e5d42183c34 *vignettes/acs-nano.csl 0ec78b946a45069323acf54a24c77566 *vignettes/american-chemical-society.csl -39365075c6f1d3ae375438054d27cb89 *vignettes/AQSAPI.bib +847af4aba6af007f68c8173be0275e23 *vignettes/AQSAPI.bib de323c3deb36e066a7583c5b756ae49b *vignettes/EPA_Disclaimer.html a79d926b2ab509e6a9e575539b205280 *vignettes/EPA_Disclaimer.Rmd 9f8f6638c5178a9bec62665b4cef5e1d *vignettes/figures/AQS_LOGO.png -ce3de92ce1a1d0851726b5ae8b384b79 *vignettes/figures/RAQSAPIhexsticker.png -44aa30dce806516fb33882e14edf4d80 *vignettes/InstallandSetup.html +52656f58a1ace48010f646376b988318 *vignettes/figures/RAQSAPIhexsticker.png +b24e9687826a95a586a2d6696af8f800 *vignettes/InstallandSetup.html 69224454907b49f3de5fcf3527a3ad3f *vignettes/InstallandSetup.Rmd -67dad9bb335f711013028746cf7ed61a *vignettes/Intro.html -07bc02844f0f6f2c93d40603e140f41b *vignettes/Intro.Rmd -bce644f7c50a618fee8429b3655e5fb9 *vignettes/RAQSAPIFunctions-Brief.html +87c86671047d619e996c248050cce085 *vignettes/Intro.html +b57a206286bec0fb22bbde308149d452 *vignettes/Intro.Rmd +c964de5f5bcde0fd3f1c7f6beaf6a4d5 *vignettes/pyaqsapi.html +ad142c2e81fca7371499f09e294c1dba *vignettes/pyaqsapi.R +733ccd06aa9a7988d1ea78f52c528e55 *vignettes/pyaqsapi.Rmd +8774f9c513ba8110c612b8ccfb9603e3 *vignettes/RAQSAPIFunctions-Brief.html 1dbae57a3f574ccd77b4d2af2c76e831 *vignettes/RAQSAPIFunctions-Brief.Rmd -9b96ebd481321226caedaa7ab4472d05 *vignettes/RAQSAPIFunctions-Long.html -c65f35b91bfac8c4f16ee2319b95d4f5 *vignettes/RAQSAPIFunctions-Long.R -e923e364682d337856051526b5b8b3a6 *vignettes/RAQSAPIFunctions-Long.Rmd -f6a1f578b9267b1182c4c3845fc68fb0 *vignettes/RAQSAPIPurpose.html -b676d49a421ed0b581e2b3269bac31e0 *vignettes/RAQSAPIPurpose.Rmd -c0099b9c0fa4d49121ad8d61078d13a7 *vignettes/RAQSAPIusagetipsandprecautions.html +f1b8ea1d165c0d47b105678c37b32c57 *vignettes/RAQSAPIFunctions-Long.html +7146486d6cb6c29314f88f0e2bbb5ab2 *vignettes/RAQSAPIFunctions-Long.R +e845be67ff86dba758853123789979e5 *vignettes/RAQSAPIFunctions-Long.Rmd +d375e86106c359f735a25d53764b7f8e *vignettes/RAQSAPIPurpose.html +2a912d01a36839facb5c2c6dff2d1c7f *vignettes/RAQSAPIPurpose.R +9d564369cb22e187ed61da9fafcac002 *vignettes/RAQSAPIPurpose.Rmd +145f6d07d3e1b62d2109d2b42885ef35 *vignettes/RAQSAPIusagetipsandprecautions.html 629b81e7f6056a9411e2ce16e4dfc5c8 *vignettes/RAQSAPIusagetipsandprecautions.Rmd -ddee30d7df25285648d9979febbe2192 *vignettes/RAQSAPIvignette.html -5f614b6e23d520d2260f9f7224fe648d *vignettes/RAQSAPIvignette.R -cc873a7101715766a6057c2cbb59609d *vignettes/RAQSAPIvignette.Rmd -3f74dfc92a4d9d85a467f20a1907fd87 *vignettes/TimelinessofAQSData.html -5d3445414bf02629a8a10b6dc05c47e7 *vignettes/TimelinessofAQSData.Rmd -06345a3820be1e248082b211e2bcb708 *vignettes/Troubleshooting.html -1fee66dbee4d04b47a0b7747ea282a5b *vignettes/Troubleshooting.Rmd -81dc9769ebde9b586474b28b17d08e72 *vignettes/UsingRAQSAPI.html +86688e02359b803ca9421cd43458bef1 *vignettes/RAQSAPIvignette.html +0ceeb543649151ff7b85d59748bacebc *vignettes/RAQSAPIvignette.R +95acca4cbbfe5ebbfcb4c0a3978038bf *vignettes/RAQSAPIvignette.Rmd +42a066ce73b20f2538877f8e4eac1d84 *vignettes/TimelinessofAQSData.html +fddf2cec564191b24c0213f260c0f932 *vignettes/TimelinessofAQSData.Rmd +3c09aefb6ebd2dd7f1e623f3eb341b6e *vignettes/Troubleshooting.html +9388c6af388ceb5b62fee3e414452c83 *vignettes/Troubleshooting.Rmd +2f01e9fde3b3c8b82aafc174e2b66833 *vignettes/UsingRAQSAPI.html 969189538d2ec6a0e10ea6d7350ab612 *vignettes/UsingRAQSAPI.Rmd diff --git a/NAMESPACE b/NAMESPACE index bcc2bb2..d47ac66 100644 --- a/NAMESPACE +++ b/NAMESPACE @@ -104,6 +104,8 @@ importFrom(dplyr,select) importFrom(dplyr,select_if) importFrom(dplyr,vars) importFrom(glue,glue) +importFrom(httr2,last_response) +importFrom(httr2,req_error) importFrom(httr2,req_options) importFrom(httr2,req_perform) importFrom(httr2,req_retry) @@ -137,6 +139,7 @@ importFrom(rlang,format_error_bullets) importFrom(rlang,is_character) importFrom(stringr,str_c) importFrom(stringr,str_detect) +importFrom(stringr,str_replace_all) importFrom(tibble,as_tibble) importFrom(tibble,tibble) importFrom(utils,tail) diff --git a/NEWS.md b/NEWS.md deleted file mode 100644 index 12e9278..0000000 --- a/NEWS.md +++ /dev/null @@ -1,8 +0,0 @@ -% News.md for RAQSAPI -% Clinton Mccrowey Physical Scientist - EPA Region 3 - Air and Radiation Division - Air Quality Analysis Branch - - -# Please see the cran-comments.md document. diff --git a/R/AQSAPI_helperfunctions.R b/R/AQSAPI_helperfunctions.R index 4a30f84..176a3a9 100644 --- a/R/AQSAPI_helperfunctions.R +++ b/R/AQSAPI_helperfunctions.R @@ -321,6 +321,44 @@ format_multiple_params_for_api <- function(x, separator=",") } +#' @title RAQSAPI_error_msg +#' +#' @param AQSresponse a httr2 request object +#' @importFrom glue glue +#' @importFrom httr2 last_response resp_body_json +#' @importFrom magrittr `%<>%` +#' @importFrom stringr str_replace_all +#' +#' @description A helper function that is called by httr2::req_error when an +#' error is encountered performing a request. This function returns +#' a helpful error message for users. This function is not intended +#' to be called directly by end users and should only be called +#' within the aqs function. +#' +#' @return a string error message that is formatted for httr2 to display +#' request errors for end users. +#' @noRd +#' +#' @example None +RAQSAPI_error_msg <- function(AQSresponse) +{ + #nocov start + AQSerr <- last_response() %>% + resp_body_json() + + #debug + msg <- glue("At server request time: {AQSresponse$headers$Date} + RAQSAPI experienced an error while processing the following url: + {AQSresponse$url} + with status_code: {AQSresponse$status_code} + and status message: {AQSresponse$status} + Server error message: {AQSerr$Header[[1]]$error}") + + return(msg) + #nocov end +} + + #' @title aqs #' @description a helper function sends a AQS RESTful request to the AQS API #' and returns the result as a aqs data type. This helper @@ -357,7 +395,7 @@ format_multiple_params_for_api <- function(x, separator=",") #' @importFrom tibble as_tibble #' @importFrom rlang caller_call #' @importFrom httr2 request req_user_agent req_url_path_append resp_body_json -#' req_perform req_options req_retry req_throttle +#' req_perform req_options req_retry req_throttle req_error #' @return a AQS_DATAMART_APIv2 S3 object that is the return value from the #' AQS API. A AQS_DATAMART_APIv2 is a 2 item named list in which the #' first item ($Header) is a tibble of header information from the @@ -381,8 +419,10 @@ aqs <- function(service, filter = NULL, user = NA, variables))) AQSrequest <- AQSpath %>% request() %>% + req_throttle(rate = 10/60, realm = "RAQSAPI") %>% - req_retry(max_tries = 5, max_seconds = 30, backoff = ~10) + req_retry(max_tries = 5, max_seconds = 30, backoff = ~10) %>% + req_error(body = RAQSAPI_error_msg) # AQS DataMart API does not accept headers so user_agent not working #%>% req_user_agent(string = user_agent) @@ -644,16 +684,16 @@ aqs_services_by_state <- function(parameter, bdate, edate, stateFIPS, { aqs(service = service, - filter = "byState", - user = getOption("aqs_username"), - user_key = getOption("aqs_key"), - variables = list(param = format_multiple_params_for_api(parameter), - bdate = format(bdate, format = "%Y%m%d"), - edate = format(edate, format = "%Y%m%d"), - state = stateFIPS, - duration = duration, - cbdate = cbdate, - cedate = cedate + filter = "byState", + user = getOption("aqs_username"), + user_key = getOption("aqs_key"), + variables = list(param = format_multiple_params_for_api(parameter), + bdate = format(bdate, format = "%Y%m%d"), + edate = format(edate, format = "%Y%m%d"), + state = stateFIPS, + duration = duration, + cbdate = cbdate, + cedate = cedate ), AQS_domain = AQS_domain ) diff --git a/R/RAQSAPI-package.R b/R/RAQSAPI-package.R index 16292f1..68c9a96 100644 --- a/R/RAQSAPI-package.R +++ b/R/RAQSAPI-package.R @@ -3,7 +3,7 @@ #' @title RAQSAPI: A R Interface to The United States Environmental Protection -#' Agency's Air Quality System Data Mart RESTful API server. +#' Agency's Air Quality System Data Mart RESTful API server #' #' @description RAQSAPI is a package for R that connects the R programming #' environment to the United State's Environmental protection agency's diff --git a/R/RAQSAPIlistfunctions.R b/R/RAQSAPIlistfunctions.R index 7b8113a..97e4fe7 100644 --- a/R/RAQSAPIlistfunctions.R +++ b/R/RAQSAPIlistfunctions.R @@ -415,7 +415,7 @@ aqs_fields_by_service <- function(service, return_header = FALSE) #' @description \lifecycle{stable} #' Returns a table of sample durations and their #' associated duration codes. Returned values are not calculated -#' durations such as 8 hour CO or O${_3}$ rolling averages, 3/6 +#' durations such as 8 hour CO or O$_3$ rolling averages, 3/6 #' day PM averages or Pb 3 month rolling averages. #' @importFrom magrittr `%<>%` #' @param return_header If FALSE (default) only returns data requested. diff --git a/R/deprecated.R b/R/deprecated.R index c63307e..b4bac15 100644 --- a/R/deprecated.R +++ b/R/deprecated.R @@ -7,7 +7,7 @@ #' @family deprecated RAQSAPI functions #' @importFrom rlang abort #' @export -#' @rdname deprecated.Rd +#' @rdname deprecated aqs_qa_annualpeferomanceeval_by_site <- function() { abort(message = "aqs_qa_annualpeferomanceeval_by* functions have been renamed @@ -26,7 +26,7 @@ aqs_qa_annualpeferomanceeval_by_site <- function() #' @family deprecated RAQSAPI functions #' @importFrom rlang abort #' @export -#' @rdname deprecated.Rd +#' @rdname deprecated aqs_qa_annualpeferomanceeval_by_county <- function() { abort(message = "aqs_qa_annualpeferomanceeval_by* functions have been renamed @@ -44,7 +44,7 @@ aqs_qa_annualpeferomanceeval_by_county <- function() #' @family deprecated RAQSAPI functions #' @importFrom rlang abort #' @export -#' @rdname deprecated.Rd +#' @rdname deprecated aqs_qa_annualpeferomanceeval_by_state <- function() { abort(message = "aqs_qa_annualpeferomanceeval_by* functions have been renamed @@ -62,7 +62,7 @@ aqs_qa_annualpeferomanceeval_by_state <- function() #' @family deprecated RAQSAPI functions #' @importFrom rlang abort #' @export -#' @rdname deprecated.Rd +#' @rdname deprecated aqs_qa_annualpeferomanceeval_by_pqao <- function() { abort(message = "aqs_qa_annualpeferomanceeval_by* functions have been renamed @@ -82,7 +82,7 @@ aqs_qa_annualpeferomanceeval_by_pqao <- function() #' @family deprecated RAQSAPI functions #' @importFrom rlang abort #' @export -#' @rdname deprecated.Rd +#' @rdname deprecated aqs_qa_annualpeferomanceeval_by_MA <- function() { abort(message = "aqs_qa_annualpeferomanceeval_by* functions have been @@ -100,7 +100,7 @@ aqs_qa_annualpeferomanceeval_by_MA <- function() #' @family deprecated RAQSAPI functions #' @importFrom rlang abort #' @export -#' @rdname deprecated.Rd +#' @rdname deprecated aqs_qa_annualpeferomanceevaltransaction_by_site <- function() { abort(message = "aqs_qa_annualpeferomanceevaltransaction_by* functions have @@ -118,7 +118,7 @@ aqs_qa_annualpeferomanceevaltransaction_by_site <- function() #' @family deprecated RAQSAPI functions #' @importFrom rlang abort #' @export -#' @rdname deprecated.Rd +#' @rdname deprecated aqs_qa_annualpeferomanceevaltransaction_by_county <- function() { abort(message = "aqs_qa_annualpeferomanceevaltransaction_by* functions have @@ -136,7 +136,7 @@ aqs_qa_annualpeferomanceevaltransaction_by_county <- function() #' @family deprecated RAQSAPI functions #' @importFrom rlang abort #' @export -#' @rdname deprecated.Rd +#' @rdname deprecated aqs_qa_annualpeferomanceevaltransaction_by_pqao <- function() { abort(message = "aqs_qa_annualpeferomanceevaltransaction_by* functions have @@ -153,7 +153,7 @@ aqs_qa_annualpeferomanceevaltransaction_by_pqao <- function() #' @family deprecated RAQSAPI functions #' @importFrom rlang abort #' @export -#' @rdname deprecated.Rd +#' @rdname deprecated aqs_qa_annualpeferomanceevaltransaction_by_MA <- function() { abort(message = "aqs_qa_annualpeferomanceevaltransaction_by* functions have diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/DESCRIPTION b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/DESCRIPTION deleted file mode 100644 index adc8d8b..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/DESCRIPTION +++ /dev/null @@ -1,97 +0,0 @@ -Type: Package -Package: RAQSAPI -Version: 2.0.5 -Title: A Simple Interface to the US EPA Air Quality System Data Mart - API -Description: Retrieve air monitoring data and associated metadata from the US - Environmental Protection Agency's Air Quality System service using functions. - See for details about - the US EPA Data Mart API. -Encoding: UTF-8 -Authors@R: c(person(given="Clinton", family="Mccrowey", - email="mccrowey.clinton@epa.gov", - role=c("cre", "aut"), - comment="United States Environmental Protection - Agency Region 3 Air and Radiation Division"), - person(given="Timothy", family="Sharac", role=c("ctb","rev"), - email=NULL, - comment="United States Environmental Protection Agency"), - person(given = "Nick", family = "Mangus", email = NULL, - role=c("rev"), - comment="United States Environmental Protection Agency"), - person(given = "Doug", family = "Jager", - email=NULL, role=c("ctb", "rev"), - comment="United States Environmental Protection Agency"), - person(given = "Ryan",family = "Brown", - email=NULL, role=c("ctb", "rev"), - comment="United States Environmental Protection Agency"), - person(given = "Daniel", family = "Garver", - email=NULL, role=c("ctb", "rev"), - comment="United States Environmental Protection Agency"), - person(given = "Benjamin", family = "Wells", - email=NULL, role=c("ctb", "rev"), - comment="United States Environmental Protection Agency"), - person(given = "Hayley", family= "Brittingham", - email = NULL, role=c("crr", "ctr"), - comment="Neptune and Company"), - person(given = "Jeffrey", family = "Hollister", - email = "hollister.jeff@epa.gov", role = c("rev"), - comment = c("United States Environmental Protection Agency", - ORCID = "0000-0002-9254-9740" - ) - ), - person(given = "Edward", family = "Andrews", - email = "edward.s.andrews@wv.gov", - role = c("rev", "ctb"), - comment = "West Virginia Department of Environmental Protection, Division of Air Quality" - ) - ) -URL: , - -BugReports: https://github.com/USEPA/RAQSAPI/issues -Depends: R (>= 4.0.0) -Imports: dplyr, glue, httr2, lifecycle, lubridate, magrittr, purrr, - rlang, stringr, tibble -Suggests: covr, devtools, goodpractice, keyring, knitr, markdown, - rmarkdown, roxygen2, spelling, testthat (>= 3.0.0), usethis, - withr -SystemRequirements: package manual requires pandoc (>= 1.14) - http://pandoc.org -RoxygenNote: 7.2.3 -VignetteBuilder: knitr -BuildVignettes: true -ByteCompile: true -License: MIT -License_is_FOSS: yes -NeedsCompilation: no -License_restricts_use: no -Language: en-US -Collate: 'AQSAPI_helperfunctions.R' 'bysite.R' 'bycounty.R' 'bystate.R' - 'byma.R' 'bypqao.R' 'bycbsa.R' 'bybox.R' - 'RAQSAPIlistfunctions.R' 'setupfunctions.R' 'zzz.R' - 'RAQSAPI-package.R' 'deprecated.R' -Copyright: United States Environmental Protection Agency -RdMacros: lifecycle -Roxygen: list(markdown = TRUE) -Config/testthat/edition: 3 -X-schema.org-keywords: United State Environmental Protection Agency, - Environmental-data-retrieval, Air-Quality-System, AQS-Datamart, - Air-monitoring, Environmental-monitoring -Packaged: 2023-08-18 13:51:20 UTC; runneradmin -Author: Clinton Mccrowey [cre, aut] (United States Environmental Protection - Agency Region 3 Air and Radiation Division), - Timothy Sharac [ctb, rev] (United States Environmental Protection - Agency), - Nick Mangus [rev] (United States Environmental Protection Agency), - Doug Jager [ctb, rev] (United States Environmental Protection Agency), - Ryan Brown [ctb, rev] (United States Environmental Protection Agency), - Daniel Garver [ctb, rev] (United States Environmental Protection - Agency), - Benjamin Wells [ctb, rev] (United States Environmental Protection - Agency), - Hayley Brittingham [crr, ctr] (Neptune and Company), - Jeffrey Hollister [rev] (United States Environmental Protection Agency, - ), - Edward Andrews [rev, ctb] (West Virginia Department of Environmental - Protection, Division of Air Quality) -Maintainer: Clinton Mccrowey diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/NAMESPACE b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/NAMESPACE deleted file mode 100644 index 15456b6..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/NAMESPACE +++ /dev/null @@ -1,142 +0,0 @@ -# Generated by roxygen2: do not edit by hand - -export(aqs_annualsummary_by_box) -export(aqs_annualsummary_by_cbsa) -export(aqs_annualsummary_by_county) -export(aqs_annualsummary_by_site) -export(aqs_annualsummary_by_state) -export(aqs_cbsas) -export(aqs_classes) -export(aqs_counties_by_state) -export(aqs_credentials) -export(aqs_dailysummary_by_box) -export(aqs_dailysummary_by_cbsa) -export(aqs_dailysummary_by_county) -export(aqs_dailysummary_by_site) -export(aqs_dailysummary_by_state) -export(aqs_fields_by_service) -export(aqs_isavailable) -export(aqs_knownissues) -export(aqs_mas) -export(aqs_monitors_by_box) -export(aqs_monitors_by_cbsa) -export(aqs_monitors_by_county) -export(aqs_monitors_by_site) -export(aqs_monitors_by_state) -export(aqs_parameters_by_class) -export(aqs_pqaos) -export(aqs_qa_annualpeferomanceeval_by_MA) -export(aqs_qa_annualpeferomanceeval_by_county) -export(aqs_qa_annualpeferomanceeval_by_pqao) -export(aqs_qa_annualpeferomanceeval_by_site) -export(aqs_qa_annualpeferomanceeval_by_state) -export(aqs_qa_annualpeferomanceevaltransaction_by_MA) -export(aqs_qa_annualpeferomanceevaltransaction_by_county) -export(aqs_qa_annualpeferomanceevaltransaction_by_pqao) -export(aqs_qa_annualpeferomanceevaltransaction_by_site) -export(aqs_qa_annualperformanceeval_by_MA) -export(aqs_qa_annualperformanceeval_by_county) -export(aqs_qa_annualperformanceeval_by_pqao) -export(aqs_qa_annualperformanceeval_by_site) -export(aqs_qa_annualperformanceeval_by_state) -export(aqs_qa_annualperformanceevaltransaction_by_MA) -export(aqs_qa_annualperformanceevaltransaction_by_county) -export(aqs_qa_annualperformanceevaltransaction_by_pqao) -export(aqs_qa_annualperformanceevaltransaction_by_site) -export(aqs_qa_annualperformanceevaltransaction_by_state) -export(aqs_qa_blanks_by_MA) -export(aqs_qa_blanks_by_county) -export(aqs_qa_blanks_by_pqao) -export(aqs_qa_blanks_by_site) -export(aqs_qa_blanks_by_state) -export(aqs_qa_collocated_assessments_by_MA) -export(aqs_qa_collocated_assessments_by_county) -export(aqs_qa_collocated_assessments_by_pqao) -export(aqs_qa_collocated_assessments_by_site) -export(aqs_qa_collocated_assessments_by_state) -export(aqs_qa_flowrateaudit_by_MA) -export(aqs_qa_flowrateaudit_by_county) -export(aqs_qa_flowrateaudit_by_pqao) -export(aqs_qa_flowrateaudit_by_site) -export(aqs_qa_flowrateaudit_by_state) -export(aqs_qa_flowrateverification_by_MA) -export(aqs_qa_flowrateverification_by_county) -export(aqs_qa_flowrateverification_by_pqao) -export(aqs_qa_flowrateverification_by_site) -export(aqs_qa_flowrateverification_by_state) -export(aqs_qa_one_point_qc_by_MA) -export(aqs_qa_one_point_qc_by_county) -export(aqs_qa_one_point_qc_by_pqao) -export(aqs_qa_one_point_qc_by_site) -export(aqs_qa_one_point_qc_by_state) -export(aqs_qa_pep_audit_by_MA) -export(aqs_qa_pep_audit_by_county) -export(aqs_qa_pep_audit_by_pqao) -export(aqs_qa_pep_audit_by_site) -export(aqs_qa_pep_audit_by_state) -export(aqs_quarterlysummary_by_box) -export(aqs_quarterlysummary_by_cbsa) -export(aqs_quarterlysummary_by_county) -export(aqs_quarterlysummary_by_site) -export(aqs_quarterlysummary_by_state) -export(aqs_removeheader) -export(aqs_revisionhistory) -export(aqs_sampledata_by_box) -export(aqs_sampledata_by_cbsa) -export(aqs_sampledata_by_county) -export(aqs_sampledata_by_site) -export(aqs_sampledata_by_state) -export(aqs_sampledurations) -export(aqs_sign_up) -export(aqs_sites_by_county) -export(aqs_states) -export(aqs_transactionsample_by_MA) -export(aqs_transactionsample_by_county) -export(aqs_transactionsample_by_site) -export(aqs_transactionsample_by_state) -importFrom(dplyr,arrange) -importFrom(dplyr,between) -importFrom(dplyr,bind_cols) -importFrom(dplyr,bind_rows) -importFrom(dplyr,mutate) -importFrom(dplyr,rename) -importFrom(dplyr,rename_at) -importFrom(dplyr,select) -importFrom(dplyr,select_if) -importFrom(dplyr,vars) -importFrom(glue,glue) -importFrom(httr2,req_options) -importFrom(httr2,req_perform) -importFrom(httr2,req_retry) -importFrom(httr2,req_throttle) -importFrom(httr2,req_url_path_append) -importFrom(httr2,req_user_agent) -importFrom(httr2,request) -importFrom(httr2,resp_body_json) -importFrom(lifecycle,badge) -importFrom(lifecycle,deprecate_soft) -importFrom(lubridate,'%within%') -importFrom(lubridate,NA_Date_) -importFrom(lubridate,day) -importFrom(lubridate,is.Date) -importFrom(lubridate,mdy) -importFrom(lubridate,month) -importFrom(lubridate,today) -importFrom(lubridate,year) -importFrom(lubridate,years) -importFrom(lubridate,ymd) -importFrom(lubridate,ymd_hm) -importFrom(magrittr,`%<>%`) -importFrom(magrittr,`%>%`) -importFrom(purrr,pmap) -importFrom(rlang,`!!`) -importFrom(rlang,`:=`) -importFrom(rlang,abort) -importFrom(rlang,call_name) -importFrom(rlang,format_error_bullets) -importFrom(rlang,is_character) -importFrom(stringr,str_c) -importFrom(stringr,str_detect) -importFrom(tibble,as_tibble) -importFrom(tibble,tibble) -importFrom(utils,tail) diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/NEWS.md b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/NEWS.md deleted file mode 100644 index c67c71d..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/NEWS.md +++ /dev/null @@ -1,8 +0,0 @@ -% News.md for RAQSAPI -% Clinton Mccrowey Physical Scientist - EPA Region III - Air and Radiation Division - Air Quality Analysis Branch - - -# Please see the cran-comments.md document. diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/AQSAPI_helperfunctions.R b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/AQSAPI_helperfunctions.R deleted file mode 100644 index a4f1470..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/AQSAPI_helperfunctions.R +++ /dev/null @@ -1,1081 +0,0 @@ -user_agent <- "RAQSAPI library for R" -server <- "AQSDatamartAPI" - - -#' @title checkaqsparams -#' @description \lifecycle{experimental} -#' a helper function used to check the validity of parameters being -#' sent to the API -#' @param ... variables to be checked. Must be one of the parameters -#' being exported RAQSAPI functions. All other -#' variables will be ignored. -#' @note This function will only check the variables exported by RAQSAPI meant -#' to be used in RAQSAPI functions. This function is not meant to be -#' called directly by the end user or to be called outside of RAQSAPI. -#' variables will remain unchanged. -#' Escaping of variables is provided by the AQS DataMart API, this -#' function is provided to assist users from receiving confusing -#' results from incorrect parameters but should not be used to verify -#' that parameters are properly escaped. -#' @importFrom lubridate is.Date -#' @importFrom rlang abort format_error_bullets call_name -#' @importFrom dplyr between -#' @importFrom glue glue -#' @importFrom magrittr `%<>%` -#' @importFrom stringr str_detect -#' @return NULL -#' @noRd -checkaqsparams <- function(...) -{ - #Note: the variable errmessage does not follow this project's style - # This is to ensure that the output string format looks nice. - errmessage <- vector() - error <- FALSE - ellipsis_args <- list(...) - names(ellipsis_args) <- names(match.call(expand.dots = FALSE)$...) - - if ("parameter" %in% names(ellipsis_args)) - { - if (nchar(ellipsis_args$parameter) != 5 | - !is.character(ellipsis_args$parameter) | - !str_detect(ellipsis_args$parameter, "^[:digit:]+$") - ) - { - error <- TRUE - errmessage %<>% c("x" = - "parameter must be a 5 digit number (represented as a character string)" - ) - } - } - - if ("stateFIPS" %in% names(ellipsis_args)) - { - if (nchar(ellipsis_args$stateFIPS) != 2 | - !is.character(ellipsis_args$stateFIPS) - ) - { - error <- TRUE - errmessage %<>% c("x" = - "stateFIPS must be a two digit number (represented as a character string), - please pad stateFIPS less than 2 digits with leading zeros" - ) - } - } - - if ("countycode" %in% names(ellipsis_args)) - { - if (nchar(ellipsis_args$countycode) != 3 | - !is.character(ellipsis_args$countycode)) - { - error <- TRUE - errmessage %<>% c("x" = - "countycode must be a three digit number (represented as a character - string), please pad countycode less than three digits with leading zeros" - ) - } - } - - if ("sitenum" %in% names(ellipsis_args)) - { - if (nchar(ellipsis_args$sitenum) != 4 | - !is.character(ellipsis_args$sitenum)) - { - error <- TRUE - errmessage %<>% c("x" = - "sitenum must be a four digit number (represented as a character string), - please pad sitenum less than four digits with leading zeros" - ) - } - } - - if ("MA_code" %in% names(ellipsis_args)) - { - if ((nchar(ellipsis_args$MA_code) != 4 | - nchar(ellipsis_args$MA_code) != 3) | - !is.character(ellipsis_args$MA_code)) - { - error <- TRUE - errmessage %<>% c("x" = - "MA_code must be a three or four digit number (represented as a character - string), please pad MA_code less than three or four digits with - leading zeros" - ) - } - } - - if ("pqao_code" %in% names(ellipsis_args)) - { - if ((nchar(ellipsis_args$pqao_code) != 4 | - nchar(ellipsis_args$pqao_code) != 3) | - !is.character(ellipsis_args$pqao_code)) - { - error <- TRUE - errmessage %<>% c("x" = - "pqao_code must be a three or four digit number (represented as a - character string), please pad pqao_code less than three or four digits - with leading zeros" - ) - } - } - if ("cbsa_code" %in% names(ellipsis_args)) - { - if (nchar(ellipsis_args$cbsa_code) != 5 | - !is.character(ellipsis_args$cbsa_code)) - { - error <- TRUE - errmessage %<>% c("x" = - "cbsa_code must be a five digit number (represented as a character - string), please pad cbsa_code less than five digits with leading zeros" - ) - } - } - if ("POC" %in% names(ellipsis_args)) - { - if (nchar(ellipsis_args$POC) != 1 | - !is.character(ellipsis_args$POC)) - { - error <- TRUE - errmessage %<>% c("x" = - "POC must be a single digit number (represented as a character string)" - ) - } - } - if ("bdate" %in% names(ellipsis_args)) - { - if (!is.Date(ellipsis_args$bdate)) - { - error <- TRUE - errmessage %<>% c("x" = "bdate must be an R date object") - } - } - if ("edate" %in% names(ellipsis_args)) - { - if (!is.Date(ellipsis_args$edate)) - { - error <- TRUE - errmessage %<>% c("x" = "edate must be an R date object") - } - } - if ("cbdate" %in% names(ellipsis_args)) - { - if (!is.Date(ellipsis_args$cbdate) & !is.null(ellipsis_args$cbdate)) - { - error <- TRUE - errmessage %<>% c("x" = "cbdate must be an R date object") - } - } - if ("cedate" %in% names(ellipsis_args)) - { - if (!is.Date(ellipsis_args$cedate) & !is.null(ellipsis_args$cedate)) - { - error <- TRUE - errmessage %<>% c("x" = "cedate must be an R date object") - } - } - if ("email" %in% names(ellipsis_args)) - { - if (!isValidEmail(ellipsis_args$email)) - { - error <- TRUE - errmessage %<>% c("x" = "invalid email address entered") - } - } - if ("minlat" %in% names(ellipsis_args)) - { - if ((!between(as.double(ellipsis_args$minlat), -90, 90)) | - !is.character(ellipsis_args$minlat)) - { - error <- TRUE - errmessage %<>% c("x" = - "minlat must be a numeric (expressed as a string) between -90 and 90" - ) - } - } - if ("maxlat" %in% names(ellipsis_args)) - { - if ((!between(as.double(ellipsis_args$maxlat), -90, 90)) | - !is.character(ellipsis_args$minlat)) - { - error <- TRUE - errmessage %<>% c("x" = - "maxlat must be a numeric (expressed as a string) between -90 and 90" - ) - } - } - if ("minlon" %in% names(ellipsis_args)) - { - if ((!between(as.double(ellipsis_args$minlon), -180, 180)) | - !is.character(ellipsis_args$minlon) - ) - { - error <- TRUE - errmessage %<>% c("x" = - "minlon must be a numeric (expressed as a string) between -180 and 180" - ) - } - } - if ("maxlon" %in% names(ellipsis_args)) - { - if ((!between(as.double(ellipsis_args$maxlon), -180, 180)) | - !is.character(ellipsis_args$maxlon) - ) - { - error <- TRUE - errmessage %<>% c("x" = - "maxlon must be a numeric (expressed as a string) between -180 and 180" - ) - } - } - if ("duration" %in% names(ellipsis_args)) - { - if (nchar(ellipsis_args$duration) != 1 | - !is.character(ellipsis_args$duration) & - ellipsis_args$duration %in% 1:9 | - ellipsis_args$duration %in% LETTERS[1:26] - ) - { - error <- TRUE - errmessage %<>% c("x" = - "duration must be a character from '1' to '9' or 'A' to 'Z' - (represented as a character string)" - ) - } - } - if ("return_header" %in% names(ellipsis_args)) - { - if (!is.logical(ellipsis_args$return_header)) - { - error <- TRUE - errmessage %<>% c("x" = "return_header must be of type logical") - } - } - if (error) - { - callingfunction <- rlang::call_name(sys.call(sys.parent(2))) - if (is.null(callingfunction)) callingfunction <- "Unknown Environment" - callingfunction <- glue(" in: {callingfunction}") - c("i" = callingfunction, errmessage) %>% abort - } -} - - -#' @title format.terms.for.api -#' @description a helper function that accepts a named list of -#' parameters and returns a string vector of -#' separator separated variables for use in -#' sending parameters to AQS RESTFUL API calls, -#' All NA and NULL values will be removed. This -#' function is not intended for use by end users. -#' @param x a named list of variables, all values will be coerced to -#' strings. -#' @param separator a string that should be used to separate variables -#' in the return value -#' @return a string that is properly formatted for use in AQS RESTFUL API -#' calls. -#' @importFrom magrittr `%>%` -#' @noRd -format_variables_for_api <- function(x, separator="&") -{ - if (length(x) == 0) { - return("") - } - #first check for NULLs, if found remove them - - x[vapply(x, is.null, FUN.VALUE = NA)] <- NULL - #don't forget to remove NAs - x[vapply(x, is.na, FUN.VALUE = NA)] <- NULL - x <- purrr::map_chr(x, as.character) - stringr::str_c(names(x), "=", x, collapse = separator) %>% - return() -} - - -#' @title format_multiple_params_for_api -#' @description a helper function that accepts a list of parameters -#' and returns a string vector of separator separated variables -#' for use in sending parameters to AQS RESTFUL API calls, All -#' NA and NULL values will be removed. This function is not -#' intended for use by end users and is specifically designed -#' for use with API code with multiple pollution codes for other -#' use cases use the generic form of this function use the -#' helper function @seealso format_variables_for_api. -#' @param x a named list of variables, all values will be coerced to -#' strings. -#' @param separator a string that should be used to separate variables -#' in the return value. -#' @return a string that is properly formatted for use in AQS RESTFUL API -#' calls. -#' @noRd -format_multiple_params_for_api <- function(x, separator=",") -{ - if (length(x) == 0) { - return("") - } - #first check for NULLs, if found remove them - - x[vapply(x, is.null, FUN.VALUE = NA)] <- NULL - #don't forget to remove NAs - x[vapply(x, is.na, FUN.VALUE = NA)] <- NULL - x <- purrr::map_chr(x, as.character) - paste0(x, collapse = separator) -} - - -#' @title aqs -#' @description a helper function sends a AQS RESTful request to the AQS API -#' and returns the result as a aqs data type. This helper -#' function is used to abstract the call to AQS API away from -#' functions that need it's result. This helper function is not -#' meant to be called directly from external functions. -#' @param service the service requested by the AQS API encoded as a string; -#' For a list of available services @seealso -#' \url{https://aqs.epa.gov/aqsweb/documents/data_api.html#services} -#' @param filter a string which represents the filter used in conjunction with -#' the service requested. For a list of available services -#' and filters @seealso -#' \url{https://aqs.epa.gov/aqsweb/documents/data_api.html#services} -#' @param user A string which represents the registered user name used to -#' connect to the AQS API. Note that the '@' character needs -#' to be escaped with the '/' character. -#' @param user_key the AQS API user key used to grant the registered user access -#' to the AQS API. -#' @param variables A named list a variables used to send to the AQS API. -#' @seealso \url{https://aqs.epa.gov/aqsweb/documents/data_api.html} -#' for the variables that are required for each -#' service/filter combination. -#' @param return_header If false (default) only reurns data requested. -#' If true returns a AQSAPI_v2 object which is a two item -#' list that contains header information returned from -#' the API server mostly used for debugging purposes in -#' addition to the data requested. -#' @param AQS_domain a R string object containing the domain that should be -#' used in constructing the API call. -#' @importFrom magrittr `%<>%` `%>%` -#' @importFrom dplyr mutate select arrange bind_cols -#' @importFrom lubridate ymd_hm -#' @importFrom glue glue -#' @importFrom tibble as_tibble -#' @importFrom httr2 request req_user_agent req_url_path_append resp_body_json -#' req_perform req_options req_retry req_throttle -#' @return a AQS_DATAMART_APIv2 S3 object that is the return value from the -#' AQS API. A AQS_DATAMART_APIv2 is a 2 item named list in which the -#' first item ($Header) is a tibble of header information from the -#' AQS API and the second item ($Data) is a tibble of the data -#' returned. -#' @noRd -aqs <- function(service, filter = NULL, user = NA, - user_key = NA, variables = NULL, AQS_domain = "aqs.epa.gov") -{ - if (is.null(user) | is.null(user_key)) - {stop("please enter user credentials before using RAQSAPI functions,\n - please refer to \'?aqs_credentials()\' for useage infomation \n" - ) - } - - user_agent <- glue("User:{user} via RAQSAPI-{packageVersion('RAQSAPI')} - library for R") - - AQSpath <- glue("https://{AQS_domain}/data/api/{service}/{filter}?") %>% - glue(format_variables_for_api(c(list(email = I(user), key = user_key), - variables))) %>% - request() %>% - req_throttle(rate = 10/60, realm = "RAQSAPI") %>% - req_retry(max_tries = 5, backoff = ~10) %>% - req_options(ssl_verifypeer = 0) #%>% - #req_user_agent(string = user_agent) - - AQStemp <- AQSpath %>% - req_perform() %>% - resp_body_json() - AQSresult <- vector("list", length = 2) - AQSresult[[1]] <- AQStemp$Header %>% - bind_cols() %>% - suppressMessages() - AQSresult[[2]] <- AQStemp$Data %>% - bind_cols() %>% - suppressMessages() - - names(AQSresult) <- c("Header", "Data") - - AQSresult <- structure(.Data = AQSresult, class = "AQS_DATAMART_APIv2") - #aqs_ratelimit() - return(AQSresult) - -} - - -#' @title isValidEmail -#' @description a helper function that checks the input string has the form -#' \\\.\ with length -#' of at least 2 can be used to check if the input has the form -#' of a valid e-mail address. -#' @param email a string which represents the parameter code of the air -#' pollutant related to the data being requested. -#' @note since this code relies on using regex the implementation is not perfect -#' and may not work as expected all the time but overall generally works -#' as expected. -#' @return Boolean -#' @noRd -isValidEmail <- function(email) { - grepl("\\<[A-Z0-9._%+-]+@[A-Z0-9.-]+\\.[A-Z]{2,}\\>", - as.character(email), - ignore.case = TRUE) -} - - -#' @title aqs_services_by_site -#' @description a helper function that abstracts the formatting of the inputs -#' for a call to aqs away from the calling function for -#' aggregations by site then calls the aqs and returns the -#' result. This helper function is not meant to be called -#' directly from external functions. -#' @family Aggregate _by_site functions -#' @param parameter a character list or a single character string -#' which represents the parameter code of the air -#' pollutant related to the data being requested. -#' @param bdate a R date object which represents that begin date of the data -#' selection. Only data on or after this date will be returned. -#' @param edate a R date object which represents that end date of the data -#' selection. Only data on or before this date will be returned. -#' @param stateFIPS a R character object which represents the 2 digit state -#' FIPS code (with leading zero) for the state being -#' requested. @seealso [aqs_states()] for the list of -#' available FIPS codes. -#' @param countycode a R character object which represents the 3 digit state -#' FIPS code for the county being requested (with leading -#' zero(s)). @seealso [aqs_counties_by_state()] for the -#' list of available county codes for each state. -#' @param sitenum a R character object which represents the 4 digit site number -#' (with leading zeros) within the county and state being -#' requested. -#' @param duration an optional R character string that represents the -#' parameter duration code that limits returned data -#' to a specific sample duration. The default value of -#' NA_character_ results in no filtering based on -#' duration code.Valid durations include actual sample -#' durations and not calculated durations such as 8 -#' hour CO or $O_3$ rolling averages, 3/6 day PM -#' averages or Pb 3 month rolling averages. -#' @seealso [aqs_sampledurations()] for a list of all -#' available duration codes. -#' @param service a string which represents the services provided by the AQS -#' API. For a list of available services @seealso -#' \url{https://aqs.epa.gov/aqsweb/documents/data_api.html#services} -#' @param cbdate a R date object which represents a "beginning -#' date of last change" that indicates when the data was last -#' updated. cbdate is used to filter data based on the change -#' date. Only data that changed on or after this date will be -#' returned. This is an optional variable which defaults -#' to NA_Date_. -#' @param cedate a R date object which represents an "end -#' date of last change" that indicates when the data was last -#' updated. cedate is used to filter data based on the change -#' date. Only data that changed on or before this date will be -#' returned. This is an optional variable which defaults -#' to NA_Date_. -#' @param AQS_domain a R string object containing the domain that should be -#' used in constructing the API call. -#' @return a AQS_DATAMART_APIv2 S3 object that is the return value from the -#' AQS API. A AQS_DATAMART_APIv2 is a 2 item named list in which the -#' first item ($Header) is a tibble of header information from the -#' AQS API and the second item ($Data) is a tibble of the data -#' returned. -aqs_services_by_site <- function(parameter, bdate, edate, - stateFIPS, countycode, sitenum, - duration = NA_character_, service, - cbdate = NA_Date_, cedate = NA_Date_, - AQS_domain = "aqs.epa.gov") -{ - aqs(service = service, - filter = "bySite", - user = getOption("aqs_username"), - user_key = getOption("aqs_key"), - variables = list(param = format_multiple_params_for_api(parameter), - bdate = format(bdate, format = "%Y%m%d"), - edate = format(edate, format = "%Y%m%d"), - state = stateFIPS, - county = countycode, - site = sitenum, - duration = duration, - cbdate = cbdate, - cedate = cedate - ), - AQS_domain = AQS_domain - ) -} - -#' @title aqs_services_by_county -#' @description a helper function that abstracts the formatting of the inputs -#' for a call to aqs away from the calling function for -#' aggregations by county then calls the aqs and returns the -#' result. This helper function is not meant to be called -#' directly from external functions. -#' @param parameter a character list or a single character string -#' which represents the parameter code of the air -#' pollutant related to the data being requested. -#' @param bdate a R date object which represents that begin date of the data -#' selection. Only data on or after this date will be returned. -#' @param edate a R date object which represents that end date of the data -#' selection. Only data on or before this date will be -#' returned. -#' @param stateFIPS a R character object which represents the 2 digit state -#' FIPS code (with leading zero) for the state being -#' requested. @seealso [aqs_states()] for the list of -#' available FIPS codes. -#' @param countycode a R character object which represents the 3 digit state -#' FIPS code for the county being requested (with leading -#' zero(s)). @seealso [aqs_counties_by_state()] for the -#' list of available county codes for each state. -#' @param duration an optional R character string that represents the -#' parameter duration code that limits returned data -#' to a specific sample duration. The default value of -#' NA_character_ results in no filtering based on -#' duration code.Valid durations include actual sample -#' durations and not calculated durations such as 8 -#' hour CO or $O_3$ rolling averages, 3/6 day PM -#' averages or Pb 3 month rolling averages. -#' @seealso [aqs_sampledurations()] for a list of all -#' available duration codes. -#' @param service a string which represents the services provided by the AQS API -#' For a list of available services @seealso -#' \url{https://aqs.epa.gov/aqsweb/documents/data_api.html#services} -#' @param cbdate a R date object which represents a "beginning -#' date of last change" that indicates when the data was last -#' updated. cbdate is used to filter data based on the change -#' date. Only data that changed on or after this date will be -#' returned. This is an optional variable which defaults -#' to NA_Date_. -#' @param cedate a R date object which represents an "end -#' date of last change" that indicates when the data was last -#' updated. cedate is used to filter data based on the change -#' date. Only data that changed on or before this date will be -#' returned. This is an optional variable which defaults -#' to NA_Date_. -#' @param AQS_domain a R string object containing the domain that should be -#' used in constructing the API call. -#' @return a AQS_DATAMART_APIv2 S3 object that is the return value from the -#' AQS API. A AQS_DATAMART_APIv2 is a 2 item named list in which the -#' first item ($Header) is a tibble of header information from the -#' AQS API and the second item ($Data) is a tibble of the data -#' returned. -aqs_services_by_county <- function(parameter, bdate, edate, - stateFIPS, countycode, service, - duration = NA_character_, - cbdate = NA_Date_, cedate = NA_Date_, - AQS_domain = "aqs.epa.gov") -{ - aqs(service = service, - filter = "byCounty", - user = getOption("aqs_username"), - user_key = getOption("aqs_key"), - variables = list(param = format_multiple_params_for_api(parameter), - bdate = format(bdate, format = "%Y%m%d"), - edate = format(edate, format = "%Y%m%d"), - state = stateFIPS, - county = countycode, - duration = duration, - cbdate = cbdate, - cedate = cedate - ), - AQS_domain = AQS_domain - ) -} - - -#' @title aqs_services_by_state -#' @description a helper function that abstracts the formatting of the inputs -#' for a call to aqs away from the calling function for -#' aggregations by State then calls the aqs and returns the -#' result. This helper function is not meant to be called -#' directly from external functions. -#' @param parameter a character list or a single character string -#' which represents the parameter code of the air -#' pollutant related to the data being requested. -#' @param bdate a R date object which represents that begin date of the data -#' selection. Only data on or after this date will be returned. -#' @param edate a R date object which represents that end date of the data -#' selection. Only data on or before this date will be returned. -#' @param stateFIPS a R character object which represents the 2 digit state -#' FIPS code (with leading zero) for the state being -#' requested. @seealso [aqs_states()] for the list of -#' available FIPS codes. -#' @param duration an optional R character string that represents the -#' parameter duration code that limits returned data -#' to a specific sample duration. The default value of -#' NA_character_ results in no filtering based on -#' duration code.Valid durations include actual sample -#' durations and not calculated durations such as 8 -#' hour CO or $O_3$ rolling averages, 3/6 day PM -#' averages or Pb 3 month rolling averages. -#' @seealso [aqs_sampledurations()] for a list of all -#' available duration codes. -#' @param service a string which represents the services provided by the -#' AQS API. For a list of available services @seealso -#' \url{https://aqs.epa.gov/aqsweb/documents/data_api.html#services} -#' @param cbdate a R date object which represents a "beginning -#' date of last change" that indicates when the data was last -#' updated. cbdate is used to filter data based on the change -#' date. Only data that changed on or after this date will be -#' returned. This is an optional variable which defaults -#' to NA_Date_. -#' @param cedate a R date object which represents an "end -#' date of last change" that indicates when the data was last -#' updated. cedate is used to filter data based on the change -#' date. Only data that changed on or before this date will be -#' returned. This is an optional variable which defaults -#' to NA_Date_. -#' @param AQS_domain a R string object containing the domain that should be -#' used in constructing the API call. -#' @return a AQS_DATAMART_APIv2 S3 object that is the return value from the -#' AQS API. A AQS_DATAMART_APIv2 is a 2 item named list in which the -#' first item ($Header) is a tibble of header information from the -#' AQS API and the second item ($Data) is a tibble of the data -#' returned. -aqs_services_by_state <- function(parameter, bdate, edate, stateFIPS, - duration = NA_character_, service, - cbdate = NA_Date_, cedate = NA_Date_, - AQS_domain = "aqs.epa.gov") -{ - - aqs(service = service, - filter = "byState", - user = getOption("aqs_username"), - user_key = getOption("aqs_key"), - variables = list(param = format_multiple_params_for_api(parameter), - bdate = format(bdate, format = "%Y%m%d"), - edate = format(edate, format = "%Y%m%d"), - state = stateFIPS, - duration = duration, - cbdate = cbdate, - cedate = cedate - ), - AQS_domain = AQS_domain - ) -} - -#' @title aqs_services_by_box -#' @description a helper function that abstracts the formatting of the inputs -#' for a call to aqs away from the calling function for -#' aggregations by a box formed by minimum/maximum -#' latitude/longitude coordinates then calls the aqs -#' and returns the result. This helper function is not meant -#' to be called directly from external functions. -#' @param parameter a character list or a single character string -#' which represents the parameter code of the air -#' pollutant related to the data being requested. -#' @param bdate a R date object which represents that begin date of the data -#' selection. Only data on or after this date will be returned. -#' @param edate a R date object which represents that end date of the data -#' selection. Only data on or before this date will be returned. -#' @param minlat a R character object which represents the minimum latitude of -#' a geographic box. Decimal latitude with north begin -#' positive. Only data north of this latitude will be -#' returned. -#' @param maxlat a R character object which represents the maximum latitude of -#' a geographic box. Decimal latitude with north begin -#' positive. Only data south of this latitude will be -#' returned. -#' @param minlon a R character object which represents the minimum longitude -#' of a geographic box. Decimal longitude with east begin -#' positive. Only data east of this longitude will be -#' returned. -#' @param maxlon a R character object which represents the maximum longitude -#' of a geographic box. Decimal longitude with east begin -#' positive. Only data west of this longitude will be -#' returned. Note that -80 is less than -70. -#' @param duration an optional R character string that represents the -#' parameter duration code that limits returned data -#' to a specific sample duration. The default value of -#' NA_character_ results in no filtering based on -#' duration code.Valid durations include actual sample -#' durations and not calculated durations such as 8 -#' hour CO or $O_3$ rolling averages, 3/6 day PM -#' averages or Pb 3 month rolling averages. -#' @seealso [aqs_sampledurations()] for a list of all -#' available duration codes. -#' @param service a string which represents the services provided by the -#' AQS API. For a list of available services @seealso -#' \url{https://aqs.epa.gov/aqsweb/documents/data_api.html#services} -#' @param cbdate a R date object which represents a "beginning date of last -#' change" that indicates when the data was last -#' updated. cbdate is used to filter data based on the change -#' date. Only data that changed on or after this date will be -#' returned. This is an optional variable which defaults -#' to NA_Date_. -#' @param cedate a R date object which represents an "end -#' date of last change" that indicates when the data was last -#' updated. cedate is used to filter data based on the change -#' date. Only data that changed on or before this date will be -#' returned. This is an optional variable which defaults -#' to NA_Date_. -#' @param AQS_domain a R string object containing the domain that should be -#' used in constructing the API call. -#' @return a AQS_DATAMART_APIv2 S3 object that is the return value from the -#' AQS API. A AQS_DATAMART_APIv2 is a 2 item named list in which the -#' first item ($Header) is a tibble of header information from the -#' AQS API and the second item ($Data) is a tibble of the data -#' returned. -aqs_services_by_box <- function(parameter, bdate, edate, minlat, maxlat, - minlon, maxlon, duration = NA_character_, - service, cbdate = NA_Date_, cedate = NA_Date_, - AQS_domain = "aqs.epa.gov") -{ - aqs(service = service, - filter = "byBox", - user = getOption("aqs_username"), - user_key = getOption("aqs_key"), - variables = list(param = format_multiple_params_for_api(parameter), - bdate = format(bdate, format = "%Y%m%d"), - edate = format(edate, format = "%Y%m%d"), - minlon = minlon, - maxlon = maxlon, - minlat = minlat, - maxlat = maxlat, - duration = duration, - cbdate = cbdate, - cedate = cedate - ), - AQS_domain = AQS_domain - ) -} - -#' @title aqs_services_by_cbsa -#' @description a helper function that abstracts the formatting of the inputs -#' for a call to aqs away from the calling function for -#' aggregations by cbsa then calls the aqs and returns the -#' result. This helper function is not meant to be called -#' directly from external functions. -#' @param parameter a character list or a single character string -#' which represents the parameter code of the air -#' pollutant related to the data being requested. -#' @param bdate a R date object which represents that begin date of the data -#' selection. Only data on or after this date will be returned. -#' @param edate a R date object which represents that end date of the data -#' selection. Only data on or before this date will be returned. -#' @param cbsa_code a R character object which represents the 5 digit AQS Core -#' Based Statistical Area code (the same as the census code, -#' with leading zeros) -#' @param duration an optional R character string that represents the -#' parameter duration code that limits returned data -#' to a specific sample duration. The default value of -#' NA_character_ results in no filtering based on -#' duration code.Valid durations include actual sample -#' durations and not calculated durations such as 8 -#' hour CO or $O_3$ rolling averages, 3/6 day PM -#' averages or Pb 3 month rolling averages. -#' @seealso [aqs_sampledurations()] for a list of all -#' available duration codes. -#' @param service a string which represents the services provided by the AQS -#' API For a list of available services @seealso -#' \url{https://aqs.epa.gov/aqsweb/documents/data_api.html#services} -#' @param cbdate a R date object which represents a "beginning -#' date of last change" that indicates when the data was last -#' updated. cbdate is used to filter data based on the change -#' date. Only data that changed on or after this date will be -#' returned. This is an optional variable which defaults -#' to NA_Date_. -#' @param cedate a R date object which represents an "end -#' date of last change" that indicates when the data was last -#' updated. cedate is used to filter data based on the change -#' date. Only data that changed on or before this date will be -#' returned. This is an optional variable which defaults -#' to NA_Date_. -#' @param AQS_domain a R string object containing the domain that should be -#' used in constructing the API call. -#' @return a AQS_DATAMART_APIv2 S3 object that is the return value from the -#' AQS API. A AQS_DATAMART_APIv2 is a 2 item named list in which the -#' first item ($Header) is a tibble of header information from the -#' AQS API and the second item ($Data) is a tibble of the data -#' returned. -aqs_services_by_cbsa <- function(parameter, bdate, edate, cbsa_code, - duration = NA_character_, service, - cbdate = NA_Date_, cedate = NA_Date_, - AQS_domain = "aqs.epa.gov") -{ - aqs(service = service, - filter = "byCBSA", - user = getOption("aqs_username"), - user_key = getOption("aqs_key"), - variables = list(param = format_multiple_params_for_api(parameter), - bdate = format(bdate, format = "%Y%m%d"), - edate = format(edate, format = "%Y%m%d"), - cbsa = cbsa_code, - duration = duration, - cbdate = cbdate, - cedate = cedate - ), - AQS_domain = AQS_domain - ) -} - -#' @title aqs_services_by_pqao -#' -#' @description a helper function that abstracts the formatting of the inputs -#' for a call to aqs away from the calling function for -#' aggregations by Primary Quality Assurance Organization (pqao) -#' then calls the aqs and returns the result. -#' This helper function is not meant to be called directly from -#' external functions. -#' -#' @param parameter a character list or a single character string -#' which represents the parameter code of the air -#' pollutant related to the data being requested. -#' -#' @param bdate a R date object which represents that begin date of the data -#' selection. Only data on or after this date will be returned. -#' -#' @param edate a R date object which represents that end date of the data -#' selection. Only data on or before this date will be returned. -#' -#' @param pqao_code a R character object which represents the 4 digit AQS -#' Primary Quality Assurance Organization code -#' (with leading zeroes). -#' -#' @param service a string which represents the services provided by the -#' AQS API. For a list of available services @seealso -#' \url{https://aqs.epa.gov/aqsweb/documents/data_api.html#services} -#' -#' @param cbdate a R date object which represents a "beginning -#' date of last change" that indicates when the data was last -#' updated. cbdate is used to filter data based on the change -#' date. Only data that changed on or after this date will be -#' returned. This is an optional variable which defaults -#' to NA_Date_. -#' -#' @param cedate a R date object which represents an "end -#' date of last change" that indicates when the data was last -#' updated. cedate is used to filter data based on the change -#' date. Only data that changed on or before this date will be -#' returned. This is an optional variable which defaults -#' to NA_Date_. -#' -#' @param AQS_domain a R string object containing the domain that should be -#' used in constructing the API call. -#' -#' @return a AQS_DATAMART_APIv2 S3 object that is the return value from the -#' AQS API. A AQS_DATAMART_APIv2 is a 2 item named list in which the -#' first item ($Header) is a tibble of header information from the -#' AQS API and the second item ($Data) is a tibble of the data -#' returned. -aqs_services_by_pqao <- function(parameter, bdate, edate, pqao_code, - service, cbdate = NA_Date_, cedate = NA_Date_, - AQS_domain = "aqs.epa.gov") -{ - aqs(service = service, - filter = "byPQAO", - user = getOption("aqs_username"), - user_key = getOption("aqs_key"), - variables = list(param = format_multiple_params_for_api(parameter), - bdate = format(bdate, format = "%Y%m%d"), - edate = format(edate, format = "%Y%m%d"), - pqao = pqao_code, - cbdate = cbdate, - cedate = cedate - ), - AQS_domain = AQS_domain - ) -} - -#' @title aqs_services_by_MA -#' @description a helper function that abstracts the formatting of the inputs -#' for a call to aqs away from the calling function for -#' aggregations by Monitoring Agency (MA) -#' then calls the aqs and returns the result. -#' This helper function is not meant to be called directly from -#' external functions. -#' @param parameter a character list or a single character string -#' which represents the parameter code of the air -#' pollutant related to the data being requested. -#' @param bdate a R date object which represents that begin date of the data -#' selection. Only data on or after this date will be returned. -#' @param edate a R date object which represents that end date of the data -#' selection. Only data on or before this date will be -#' returned. -#' @param MA_code a R character object which represents the 4 digit AQS -#' Monitoring Agency code (with leading zeroes). -#' @param service a string which represents the services provided by the AQS API -#' For a list of available services @seealso -#' \url{https://aqs.epa.gov/aqsweb/documents/data_api.html#services} -#' @param cbdate a R date object which represents a "beginning -#' date of last change" that indicates when the data was last -#' updated. cbdate is used to filter data based on the change -#' date. Only data that changed on or after this date will be -#' returned. This is an optional variable which defaults -#' to NA_Date_. -#' @param cedate a R date object which represents an "end -#' date of last change" that indicates when the data was last -#' updated. cedate is used to filter data based on the change -#' date. Only data that changed on or before this date will be -#' returned. This is an optional variable which defaults -#' to NA_Date_. -#' @param AQS_domain a R string object containing the domain that should be -#' used in constructing the API call. -#' @return a AQS_DATAMART_APIv2 S3 object that is the return value from the -#' AQS API. A AQS_DATAMART_APIv2 is a 2 item named list in which the -#' first item ($Header) is a tibble of header information from the -#' AQS API and the second item ($Data) is a tibble of the data -#' returned. -aqs_services_by_MA <- function(parameter, bdate, edate, MA_code, service, - cbdate = NA_Date_, cedate = NA_Date_, - AQS_domain = "aqs.epa.gov") -{ - aqs(service = service, - filter = "byMA", - user = getOption("aqs_username"), - user_key = getOption("aqs_key"), - variables = list(param = format_multiple_params_for_api(parameter), - bdate = format(bdate, format = "%Y%m%d"), - edate = format(edate, format = "%Y%m%d"), - agency = MA_code, - cbdate = cbdate, - cedate = cedate - ), - AQS_domain = AQS_domain - ) -} - -#' @title aqs_metadata_service -#' @description A helper function for functions which use the metaData service -#' from the AQS API. This function is not intended to be called -#' directly by the end user -#' @param filter a character string representing the filter being applied -#' @param service a character string representing the service -#' @param AQS_domain a R string object containing the domain that should be -#' used in constructing the API call. -#' @return a AQS_DATAMART_APIv2 S3 object that is the return value from the -#' AQS API. A AQS_DATAMART_APIv2 is a 2 item named list in which the -#' first item ($Header) is a tibble of header information from the -#' AQS API and the second item ($Data) is a tibble of the data -#' returned. -aqs_metadata_service <- function(filter, service = NA_character_, - AQS_domain = "aqs.epa.gov") -{ - aqs(service = "metaData", - filter = filter, - user = getOption("aqs_username"), - user_key = getOption("aqs_key"), - variables = list(service = service), - AQS_domain = AQS_domain - ) -} - - -#' @title renameaqsvariables -#' @description \lifecycle{experimental} -#' This is a helper function not intended to be called directly -#' by the end user. Renames the two columns returned in the $Data -#' portion of a RAQSAPI_v2 object from "value"and -#' "value_represented" to name1 and name2 respectively. -#' @importFrom dplyr rename rename_at vars -#' @importFrom rlang `:=` `!!` -#' @param aqsobject A RAQSAPI_v2 object -#' @param name1 a character string representing the new name of the first -#' column of the $Data portion of the RAQSAPI_v2 object. -#' @param name2 a character string representing the new name of the second -#' column of the $Data portion of the RAQSAPI_v2 object. -#' @noRd -renameaqsvariables <- function(aqsobject, name1, name2) -{ -if (is.null(aqsobject)) - { - return(aqsobject) - } else if(inherits(x = aqsobject, what = "AQS_DATAMART_APIv2")) - { - #using tidyevaluation and substitute operator - aqsobject$Data %<>% dplyr::rename(!!name1 := 1) - aqsobject$Data %<>% dplyr::rename(!!name2 := 2) - - } else if (all(inherits(x = aqsobject[[1]], what = "AQS_DATAMART_APIv2"))) - { - #using tidyevaluation and substitute operator - aqsobject %<>% lapply("[[", "Data") %>% - dplyr::rename(!!name1 := 1) - aqsobject %<>% lapply("[[", "Data") %>% - dplyr::rename(!!name2 := 2) - } - return(aqsobject) -} - - -#' @title aqsmultiyearparams -#' @description \lifecycle{experimental} -#' This is a helper function intended to build a tibble of -#' parameters used to generate the inputs to the purrr::map -#' functions used with functional calls to services_by_* -#' functions. This function is not intended for end use by the -#' user. -#' @param parameter a character list or a single character string -#' which represents the parameter code of the air -#' pollutant related to the data being requested. -#' @param bdate a R date object which represents that begin date of the data -#' selection. Only data on or after this date will be returned. -#' @param edate a R date object which represents that end date of the data -#' selection. Only data on or before this date will be returned. -#' @param ... Other parameters returned to the calling function. -#' @importFrom rlang abort -#' @importFrom utils tail -#' @importFrom stringr str_c -#' @importFrom tibble tibble -#' @importFrom lubridate year ymd month day years -#' @importFrom glue glue -#' @importFrom dplyr select_if -#' @importFrom magrittr `%>%` `%<>%` -#' @noRd -aqsmultiyearparams <- function(parameter, bdate, edate, service, ...) -{ - ellipsis_args <- list(...) - if (bdate > edate) - { - return(rlang::abort(message = "bdate > edate")) - } else if (year(bdate) == year(edate)) - { - bdatevector <- bdate - edatevector <- edate - - } else if (year(bdate) < year(edate)) - { - bdatevector <- c(bdate, seq.Date(from = ymd( - glue("{year(bdate) + 1}-1-1") - ), - to = edate, by = "year") - ) - if (month(edate) != 12 && day(edate) != 31) - { - edatevector <- c(seq.Date(from = ymd(glue("{year(bdate)}-12-31" - ) - ), - to = edate, by = "year"), edate) - } else - { - edatevector <- seq.Date(from = ymd(glue("{year(bdate)}-12-31")), - to = edate, by = "year") - } - } - if (length(bdatevector) > length(edatevector)) - { - edatevector %<>% c(ymd(tail(edatevector, n = 1)) + years(1)) - } - params <- tibble(parameter = format_multiple_params_for_api(parameter), - bdate = bdatevector, - edate = edatevector, - stateFIPS = ellipsis_args$stateFIPS, - countycode = ellipsis_args$countycode, - sitenum = ellipsis_args$sitenum, - service = service, - cbdate = ellipsis_args$cbdate, - cedate = ellipsis_args$cedate, - minlat = ellipsis_args$minlat, - maxlat = ellipsis_args$maxlat, - minlon = ellipsis_args$minlon, - maxlon = ellipsis_args$maxlon, - cbsa_code = ellipsis_args$cbsa_code, - pqao_code = ellipsis_args$pqao_code, - MA_code = ellipsis_args$MA_code, - filter = ellipsis_args$filter, - AQS_domain = ellipsis_args$AQS_domain - ) - params %>% - #remove all columns that have all NA values - dplyr::select_if(function(x) {!all(is.na(x))}) %>% - return() -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/RAQSAPI-package.R b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/RAQSAPI-package.R deleted file mode 100644 index 44fd030..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/RAQSAPI-package.R +++ /dev/null @@ -1,43 +0,0 @@ -#' @importFrom lubridate today year mdy '%within%' NA_Date_ -#' @importFrom lifecycle deprecate_soft badge - - -#' @title RAQSAPI: A R Interface to The United States Environmental Protection -#' Agency's Air Quality System Data Mart RESTful API server. -#' -#' @description RAQSAPI is a package for R that connects the R programming -#' environment to the United State's Environmental protection agency's -#' Air Quality System (AQS) Data Mart API for retrieval of air -#' monitoring data. -#' -#' There are two things that you must do before using this package. -#' 1) If you have not done so yet register your username with Data Mart -#' 2) Every time this library is reloaded AQS_API_credentials() function -#' must be called before continuing. -#' -#' please use vignette(RAQSAPI) for more details about this package. -#' -#' EPA Disclaimer: -#' This software/application was developed by the U.S. Environmental Protection -#' Agency (USEPA). No warranty expressed or implied is made regarding the -#' accuracy or utility of the system, nor shall the act of distribution -#' constitute any such warranty. The USEPA has relinquished control of the -#' information and no longer has responsibility to protect the integrity, -#' confidentiality or availability of the information. Any reference to specific -#' commercial products, processes, or services by service mark, trademark, -#' manufacturer, or otherwise, does not constitute or imply their endorsement, -#' recommendation or favoring by the USEPA. The USEPA seal and logo shall not -#' be used in any manner to imply endorsement of any commercial product or -#' activity by the USEPA or the United States Government. -#' @docType package -#' @name RAQSAPI -#' @keywords internal -"_PACKAGE" -NULL - - -## usethis namespace: start -#' @importFrom lifecycle deprecate_soft -#' @importFrom lifecycle deprecated -##' importFrom lifecycle deprecate_soft badge -## usethis namespace: end diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/RAQSAPIlistfunctions.R b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/RAQSAPIlistfunctions.R deleted file mode 100644 index 29d0f28..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/RAQSAPIlistfunctions.R +++ /dev/null @@ -1,463 +0,0 @@ -#' @section list functions - - -#' @title aqs_isavailable -#' @description \lifecycle{stable} -#' returns a tibble or an AQS_Data Mart_APIv2 S3 object -#' explaining the status of the AQS API. -#' @importFrom magrittr `%>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object which details the status -#' of the AQS API (The status information is located in the header) -#' @examples -#' # Check if the AQS API is up, running and accepting requests. -#' \dontrun{ aqs_isAvailable() } -#' @export -aqs_isavailable <- function(return_header = FALSE) -{ - if (!return_header) - { - aqs(service = "metaData", - filter = "isAvailable", - user = getOption("aqs_username"), - user_key = getOption("aqs_key") - )$Header %>% - return() - } else - { - aqs(service = "metaData", - filter = "isAvailable", - user = getOption("aqs_username"), - user_key = getOption("aqs_key") - ) - } -} - - -#' @title aqs_knownissues -#' @description \lifecycle{stable} -#' Returns a table of any known issues with system functionality -#' or the data. These are usually issues that have been -#' identified internally and will require some time to correct -#' in Data Mart or the API. This function implements a direct -#' API call to Data Mart and returns data directly from the API. -#' Issues returned via this function do not include any issues -#' from the RAQSAPI R package. -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. If TRUE -#' returns a AQSAPI_v2 object which is a two item list that contains header -#' information returned from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object that contains -#' information involving known issues with the Data Mart API. -#' @examples -#' # Retrieve a tibble of known issues directly from the AQS data mart API -#' \dontrun{aqs_knownissues()} -#' @export -aqs_knownissues <- function(return_header = FALSE) -{ - issues <- aqs_metadata_service(filter = "issues", service = NULL) - if (!return_header) issues %<>% aqs_removeheader - return(issues) - -} - - -#' @title aqs_counties_by_state -#' @description \lifecycle{stable} -#' Returns a table of all counties in within the -#' stateFIPS provided. -#' @importFrom magrittr `%<>%` -#' @param stateFIPS a R character object which represents the 2 digit state -#' FIPS code (with leading zeros) for the state being -#' requested. @seealso [aqs_states()] for the list of -#' available FIPS codes. -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object of all counties in the -#' requested state. -#' @examples -#' # Returns a tibble all the counties -#' # in North Carolina the county FIPS codes (county codes) for -#' # each. -#' \dontrun{aqs_counties_by_state(stateFIPS = "37")} -#' @export -aqs_counties_by_state <- function(stateFIPS, return_header = FALSE) -{ - counties <- aqs(service = "list", - filter = "countiesByState", - user = getOption("aqs_username"), - user_key = getOption("aqs_key"), - variables = list(state = stateFIPS) - ) - counties %<>% renameaqsvariables(name1 = "county_code", - name2 = "county_name") - if (!return_header) counties %<>% aqs_removeheader - return(counties) - -} - - -#' @title aqs_sites_by_county -#' @description \lifecycle{stable} -#' Returns data containing a table of all air monitoring sites -#' with the input state and county FIPS code combination. -#' @inheritParams aqs_services_by_county -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object of all air monitoring -#' sites with the requested state and county FIPS codes. -#' @examples # Returns an AQS_Data Mart_APIv2 S3 object witch returns all sites -#' # in Hawaii County, HI -#' \dontrun{aqs_sites_by_county(stateFIPS = "15", -#' countycode = "001") -#' } -#' @export -aqs_sites_by_county <- function(stateFIPS, countycode, return_header = FALSE) -{ - sites <- aqs(service = "list", - filter = "sitesByCounty", - user = getOption("aqs_username"), - user_key = getOption("aqs_key"), - variables = list(state = stateFIPS, - county = countycode - ) - ) - sites %<>% renameaqsvariables(name1 = "site_number", name2 = "site_name") - if (!return_header) sites %<>% aqs_removeheader - return(sites) - -} - - -#' @title aqs_classes -#' @description \lifecycle{stable} -#' Returns a table of Parameter classes (groups of parameters, -#' i.e. "criteria" or "all"). The information from this function -#' can be used as input to other API calls. -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object of Parameter classes -#' (groups of parameters, i.e. "criteria" or "all"). -#' @examples # Returns a tibble of parameter classes (groups of parameters, i.e. -#' # "criteria" or all") -#' \dontrun{ aqs_classes() } -#' @export -aqs_classes <- function(return_header = FALSE) -{ - classes <- aqs(service = "list", - filter = "classes", - user = getOption("aqs_username"), - user_key = getOption("aqs_key"), - variables = NULL - ) - - if (!return_header) classes %<>% aqs_removeheader - return(classes) -} - - -#' @title aqs_parameters_by_class -#' @description \lifecycle{stable} -#' Returns parameters associated with the input class. -#' @importFrom magrittr `%<>%` -#' @param class a R character object that represents the class requested, -#' @seealso [aqs_classes()] for retrieving -#' available classes. The class R character object must be a -#' valid class as returned from aqs_classes(). The class must -#' be an exact match to what is returned from aqs_classes() -#' (case sensitive). -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing the -#' parameters associated with the class requested. NULL is returned -#' for classes not found. -#' @examples # Returns a tibble of AQS parameters in the criteria class -#' \dontrun{ aqs_parameters_by_class(class = "CRITERIA") } -#' @export -aqs_parameters_by_class <- function(class, return_header = FALSE) -{ - parameters <- aqs(service = "list", - filter = "parametersByClass", - user = getOption("aqs_username"), - user_key = getOption("aqs_key"), - variables = list(pc = class) - ) - if (!return_header) parameters %<>% aqs_removeheader - return(parameters) -} - - -#' @title aqs_mas -#' @description \lifecycle{stable} -#' Returns a table of monitoring agencies (MA). -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object of monitoring agencies -#' and their associated agency code. -#' @examples # Returns a tibble or an AQS_Data Mart_APIv2 S3 object -#' # of monitoring agencies and their respective -#' # monitoring agency codes. -#' \dontrun{aqs_mas()} -#' @export -aqs_mas <- function(return_header = FALSE) -{ - mas <- aqs(service = "list", - filter = "mas", - user = getOption("aqs_username"), - user_key = getOption("aqs_key"), - variables = NULL - ) - mas %<>% renameaqsvariables(name1 = "MA_code", name2 = "MonitoringAgency") - if (!return_header) mas %<>% aqs_removeheader - return(mas) -} - - -#' @title aqs_pqaos -#' @description \lifecycle{stable} -#' Returns a table of primary quality assurance -#' organizations (pqaos). -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object of pqaos and -#' their associated pqao code. -#' @examples # Returns a tibble of primary quality assurance -#' # organizations (pqaos) -#' \dontrun{ aqs_pqaos() } -#' @export -aqs_pqaos <- function(return_header = FALSE) -{ - pqaos <- aqs(service = "list", - filter = "pqaos", - user = getOption("aqs_username"), - user_key = getOption("aqs_key"), - variables = NULL - ) - pqaos %<>% renameaqsvariables(name1 = "PQAO_code", name2 = "PQAO") - if (!return_header) pqaos %<>% aqs_removeheader - return(pqaos) -} - - -#' @title aqs_cbsas -#' @description \lifecycle{stable} -#' Returns a table of all Core Based Statistical Areas (cbsa) -#' and their associated cbsa_codes. for constructing other -#' requests. -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object of all Core Based -#' Statistical Areas (cbsa) and their cbsa_codes for constructing -#' other requests. -#' @examples # Returns a tibble of Core Based Statistical Areas (cbsas) -#' # and their respective cbsa codes -#' \dontrun{ aqs_cbsas() } -#' @export -aqs_cbsas <- function(return_header = FALSE) -{ - cbsas <- aqs(service = "list", - filter = "cbsas", - user = getOption("aqs_username"), - user_key = getOption("aqs_key"), - variables = NULL - ) - - cbsas %<>% renameaqsvariables(name1 = "CBSA_code", name2 = "CBSA_name") - if (!return_header) cbsas %<>% aqs_removeheader - return(cbsas) -} - - -#' @title aqs_states -#' @description \lifecycle{stable} -#' Returns a table of US states, US territories, and the -#' district or Columbia with their respective FIPS codes. -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns an AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object of states and their -#' associated FIPS codes. -#' @examples # Returns a tibble of states and their FIPS codes -#' \dontrun{aqs_states()} -#' @export -aqs_states <- function(return_header = FALSE) -{ - states <- aqs(service = "list", - filter = "states", - user = getOption("aqs_username"), - user_key = getOption("aqs_key"), - variables = NULL - ) - states %<>% renameaqsvariables(name1 = "stateFIPS", name2 = "state") - if (!return_header) states %<>% aqs_removeheader - return(states) -} - - -#' @title aqs_removeheader -#' @description \lifecycle{stable} -#' Coerces a single AQS_Data_Mart_APIv2 S3 object or -#' a list of AQS_Data_Mart_APIv2 S3 objects into a single tibble -#' object. This function decouples the $Data from the AQSAPI_v2 -#' object and returns only the $Data portion as a tibble. If the -#' input is a list of AQSAPI_v2 objects combines the $Data -#' portion of each AQS_Data_Mart_APIv2 S3 object into a single -#' tibble with $Header information discarded. Else returns the -#' input with no changes. -#' @note Since this function returns only the $Data portion of RAQSAPI_v2 -#' objects this means that the $Header information will not be present in the -#' object being returned. -#' @param AQSobject An object of AQSAPI_v2 or a list of AQSAPI_v2 objects. -#' @importFrom dplyr bind_rows -#' @return a tibble of the combined $data portions of the input -#' AQS_Data_Mart_APIv2 S3 object with the $Header portion discarded. -#' @examples -#' \dontrun{ AQSobject <- aqs_removeheader(AQSobject)} -#' @export -aqs_removeheader <- function(AQSobject) -{ - if (is.null(AQSobject)) - { - return(AQSobject) - } else if (isa(x = AQSobject, what = "AQS_DATAMART_APIv2")) - #if (class(AQSobject) %in% "AQS_DATAMART_APIv2") - { - AQSobject <- AQSobject$Data - } else if (isa(x = AQSobject[[1]], what = "AQS_DATAMART_APIv2") && - is.list(AQSobject)) - { - AQSobject %<>% lapply("[[", "Data") %>% - dplyr::bind_rows() - } - - return(AQSobject) -} - - -#' @title aqs_revisionhistory -#' -#' @description \lifecycle{stable} -#' Returns the change history to the AQS Data Mart API. -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. If TRUE -#' returns a AQSAPI_v2 object which is a two item list that contains header -#' information returned from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object that is the return value -#' from the AQS API. A AQS_Data Mart_APIv2 is a 2 item named list in which the -#' first item ($Header) is a tibble of header information from the AQS API -#' and the second item ($Data) is a tibble of the data -#' returned. -#' @examples -#' # Returns a DataFrame of the EPA AQS Data Mart API revision history -#' # \dontrun{aqs_revisionHistory()} -#' @export -aqs_revisionhistory <- function(return_header = FALSE) -{ - history <- aqs(service = "metaData", - filter = "revisionHistory", - user = getOption("aqs_username"), - user_key = getOption("aqs_key"), - variables = NULL - ) - if (!return_header) history %<>% aqs_removeheader - return(history) -} - -#' @title aqs_fieldsbyservice -#' @description \lifecycle{stable} -#' Returns a tibble or an AQS_Data Mart_APIv2 S3 -#' object with the list and definitions of fields in the -#' service requested. -#' @importFrom magrittr `%<>%` -#' @param service a string which represents the services provided by the AQS -#' API. For a list of available services -#' @seealso \url{https://aqs.epa.gov/aqsweb/documents/data_api.html#services -#' } -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @examples # Returns a tibble containing a list and definitions -#' # of fields in the Sample Data service -#' \dontrun{aqs_fieldsbyservice(service = "sampleData")} -#' -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object with containing the list -#' and definitions of fields requested service -#' @export -aqs_fields_by_service <- function(service, return_header = FALSE) -{ - fields <- aqs_metadata_service(filter = "fieldsByService", service = service) - if (!return_header) fields %<>% aqs_removeheader - return(fields) -} - - -#' @title aqs_sampledurations -#' @description \lifecycle{stable} -#' Returns a table of sample durations and their -#' associated duration codes. Returned values are not calculated -#' durations such as 8 hour CO or O${_3}$ rolling averages, 3/6 -#' day PM averages or Pb 3 month rolling averages. -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object of sample durations and -#' their associated duration codes -#' (groups of parameters, i.e. "criteria" or "all"). -#' @examples # Returns a tibble or an AQS_Data Mart_APIv2 S3 object of -#' \dontrun{ aqs_sampledurations() } -#' @export -aqs_sampledurations <- function(return_header = FALSE) -{ - AQS_domain <- "aqs.epa.gov" - - durations <- aqs(service = "list", - filter = "duration", - user = getOption("aqs_username"), - user_key = getOption("aqs_key"), - variables = NULL, - AQS_domain = AQS_domain - ) - - if (!return_header) durations %<>% aqs_removeheader - return(durations) -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/bybox.R b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/bybox.R deleted file mode 100644 index 911aca5..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/bybox.R +++ /dev/null @@ -1,367 +0,0 @@ -#' @section by_box aggregate functions - - -#' @title aqs_monitors_by_box -#' @description \lifecycle{stable} -#' Returns a table of monitors and related metadata sites with the provided -#' parameter, aggregated by latitude/longitude bounding box (_by_box) for -#' bdate - edate time frame. -#' @note All monitors that operated between the bdate and edate will be returned -#' @family Aggregate _by_box functions -#' @inheritParams aqs_services_by_box -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. If TRUE -#' returns a AQSAPI_v2 object which is a two item list that contains header -#' information returned from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object of monitors from a -#' latitude/longitude bounding box (_by_box). -#' @examples # Returns a tibble of all ozone -#' # monitors in the vicinity of central Alabama that operated in -#' # 1995 -#' \dontrun{aqs_monitors_by_box(parameter="44201", -#' bdate=as.Date("19950101", -#' format="%Y%m%d"), -#' edate=as.Date("19951231", -#' format="%Y%m%d"), -#' minlat="33.3", -#' maxlat="33.6", -#' minlon="-87.0", -#' maxlon="-86.7" -#' ) -#' } -#' @export -aqs_monitors_by_box <- function(parameter, bdate, edate, minlat, maxlat, - minlon, maxlon, return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, minlat, maxlat, minlon, maxlon, - return_header) - - # aqs_monitors_by_* functions don't call aqsmultiyearparams() since the - # monitors API call accepts multiple years of data on the server, purrr::map - # is used so that the output is consistent with other RAQSAPI functions. - params <- tibble(parameter = parameter, - bdate = bdate, - edate = edate, - minlat = minlat, - maxlat = maxlat, - minlon = minlon, - maxlon = maxlon, - service = "monitors" - ) %>% - dplyr::select_if(function(x) {!all(is.na(x))}) - - monitors <- purrr::pmap(.l = params, .f = aqs_services_by_box) - if (!return_header) monitors %<>% aqs_removeheader - return(monitors) -} - - -#' @title aqs_sampledata_by_box -#' @description \lifecycle{stable} -#' Returns sample data where the data is aggregated by -#' latitude/longitude bounding box (_by_box). -#' If return_header is FALSE (default) this function returns a -#' single dataframe with the requested data. If return_header -#' is TRUE returns a list of AQSAPI_v2 objects where each index -#' of the list is an individual RAQSAPI_v2 object returned from -#' each successive call to the AQS API. RAQSAPI_v2 objects are -#' two item list where the $Data portion contains data that -#' contains sample air monitoring data at a site with the input -#' parameter and cbsa_code provided for bdate - edate time -#' frame. The $Header is a tibble of header information from the -#' API call /(useful for debugging/). This function returns NULL -#' is bdate > edate. -#' @note The AQS API only allows for a single year of sampledata to be retrieved -#' at a time. This function conveniently extracts date information from -#' the bdate and edate parameters then makes repeated calls to the -#' AQSAPI retrieving a maximum of one calendar year of data at a time. -#' Each calendar year of data requires a separate API call so multiple -#' years of data will require multiple API calls. As the number of years -#' of data being requested increases so does the length of time that it -#' will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_box functions -#' @inheritParams aqs_services_by_box -#' @importFrom magrittr `%<>%` -#' @importFrom purrr pmap -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two item -#' list that contains header information returned from -#' the API server mostly used for debugging purposes in -#' addition to the data requested. -#' @return a tibble or an AQS_Data_Mart_APIv2 S3 object containing sample data -#' for all monitors within the input latitude/longitude bounding box -#' for a single parameter. An AQS_Data Mart_APIv2 is a 2 item named -#' list in which the first item /(/$Header/) is a tibble of header -#' information from the AQS API and the second item /(/$Data/) is a -#' tibble of the data returned. -#' @examples # Returns a tibble containing all ozone samples -#' # in the vicinity of central Alabama between -#' # May 1, 2015 - May 2, 2017 -#' \dontrun{aqs_sampledata_by_box(parameter = "44201", -#' bdate = as.Date("20150501", -#' format = "%Y%m%d"), -#' edate = as.Date("20170502", -#' format = "%Y%m%d"), -#' minlat = "33.3", -#' maxlat = "33.6", -#' minlon = "-87.0", -#' maxlon = "-86.7" -#' ) -#' } -#' @export -aqs_sampledata_by_box <- function(parameter, bdate, edate, minlat, maxlat, - minlon, maxlon, - duration = NA_character_, - cbdate = NA_Date_, cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, minlat, maxlat, minlon, maxlon, - duration, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - minlat = minlat, - maxlat = maxlat, - minlon = minlon, - maxlon = maxlon, - duration = duration, - service = "sampleData", - cbdate = cbdate, - cedate = cedate - ) - - sampledata <- purrr::pmap(.l = params, .f = aqs_services_by_box) - if (!return_header) sampledata %<>% aqs_removeheader - return(sampledata) -} - - -#' @title aqs_annualsummary_by_box -#' @description \lifecycle{stable} -#' Returns multiple years of data where annual data is -#' aggregated at the bounding box level. Returned is an annual -#' summary within the input parameter, latitude/longitude -#' bounding box provided for bdate - edate time frame. Variables -#' returned include mean value, maxima, percentiles, and etc. If -#' return_header is FALSE (default) the object returned is a -#' tibble, if TRUE an AQS_API_v2 object. -#' @note The AQS API only allows for a single year of annualsummary to be -#' retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_box functions -#' @inheritParams aqs_services_by_box -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. If TRUE -#' returns a AQSAPI_v2 object which is a two item list that contains header -#' information returned from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object that containing annual -#' summary data for the box (area) requested. A AQS_Data Mart_APIv2 -#' is a 2 item named list in which the first item ($Header) is a -#' tibble of header information from the AQS API and the second item -#' ($Data) is a tibble of the data returned. -#' @examples # Returns a tibble containing ozone annual summaries -#' # in the vicinity of central Alabama for the first two days -#' # of May, 2015 -#' \dontrun{aqs_annualsummary_by_box(parameter = "44201", -#' bdate = as.Date("20150501", -#' format = "%Y%m%d"), -#' edate = as.Date("20170502", -#' format = "%Y%m%d"), -#' minlat = "33.3", -#' maxlat = "33.6", -#' minlon = "-87.0", -#' maxlon = "-86.7" -#' ) -#' } -#' @export -aqs_annualsummary_by_box <- function(parameter, bdate, edate, minlat, maxlat, - minlon, maxlon, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, minlat, maxlat, minlon, maxlon, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - minlat = minlat, - maxlat = maxlat, - minlon = minlon, - maxlon = maxlon, - service = "annualData", - cbdate = cbdate, - cedate = cedate - ) - - annualsummary <- purrr::pmap(.l = params, .f = aqs_services_by_box) - if (!return_header) annualsummary %<>% aqs_removeheader - return(annualsummary) - -} - - -#' @title aqs_dailysummary_by_box -#' @description \lifecycle{stable} -#' Returns a tibble or an AQS_Data Mart_APIv2 S3 -#' object containing daily summary data bounded within a -#' latitude/longitude bounding box -#' @note The AQS API only allows for a single year of dailysummary to be -#' retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate_by_box functions -#' @inheritParams aqs_services_by_box -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two item -#' list that contains header information returned from -#' the API server mostly used for debugging purposes in -#' addition to the data requested. -#' @return a tibble or an AQS_Data_Mart_APIv2 S3 object that contains daily -#' summary statistics for the given parameter for an area bounded -#' within a latitude/longitude bounding box. An AQS_Data Mart_APIv2 is -#' a 2 item named list in which the first item ($Header) is a tibble -#' of header information from the AQS API and the second item ($Data) -#' is a tibble of the data returned. -#' @examples #Returns a tibble of ozone daily summaries in the vicinity of -#' # central Alabama for the first two days of May 2015 -#' -#' \dontrun{aqs_dailysummary_by_box(parameter = "44201", -#' bdate = as.Date("20140501", -#' format = "%Y%m%d" -#' ), -#' edate = as.Date("20160502", -#' format = "%Y%m%d" -#' ), -#' mqinlat ="33.3", -#' maxlat = "33.6", -#' minlon = "-87.0", -#' maxlon = "-86.7" -#' ) -#' } -#' @export -aqs_dailysummary_by_box <- function(parameter, bdate, edate, minlat, maxlat, - minlon, maxlon, cbdate = NA_Date_, - cedate = NA_Date_, return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, minlat, maxlat, minlon, maxlon, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - minlat = minlat, - maxlat = maxlat, - minlon = minlon, - maxlon = maxlon, - service = "dailyData", - cbdate = cbdate, - cedate = cedate - ) - - dailysummary <- purrr::pmap(.l = params, .f = aqs_services_by_box) - if (!return_header) dailysummary %<>% aqs_removeheader - return(dailysummary) -} - - -#' @title aqs_quarterlysummary_by_box -#' @description \lifecycle{stable} -#' Returns a tibble or an AQS_Data Mart_APIv2 S3 -#' object of quarterly summary data aggregated by and area within -#' a latitude/longitude bounding box. -#' @note The AQS API only allows for a single year of quarterly summary to be -#' retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' -#' Also Note that for quarterly data, only the year portion of the bdate -#' and edate are used and all 4 quarters in the year are returned. -#' @family Aggregate _by_state functions -#' @inheritParams aqs_services_by_box -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object that contains quarterly -#' summary statistics for an area within a latitude/longitude -#' bounding box. An AQS_Data Mart_APIv2 is a 2 item named list in -#' which the first item ($Header) is a tibble of header information -#' from the AQS API and the second item ($Data) is a tibble of the -#' data returned. -#' @examples # Returns a tibble containing ozone quarterly summaries -#' # in the vicinity of central Alabama for each quarter in -#' # between 2015 - 2017 -#' \dontrun{aqs_quarterlysummary_by_box(parameter = "44201", -#' bdate = as.Date("20150101", -#' format = "%Y%m%d"), -#' edate = as.Date("20171231", -#' format = "%Y%m%d"), -#' minlat = "33.3", -#' maxlat = "33.6", -#' minlon = "-87.0", -#' maxlon = "-86.7" -#' ) -#' } -#' @export -aqs_quarterlysummary_by_box <- function(parameter, bdate, edate, minlat, maxlat, - minlon, maxlon, cbdate = NA_Date_, - cedate = NA_Date_, return_header = FALSE - ) -{ - AQS_domain <- "aqs.epa.gov" - checkaqsparams(parameter, bdate, edate, minlat, maxlat, - minlon, maxlon, cbdate, cedate, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - minlat = minlat, - maxlat = maxlat, - minlon = minlon, - maxlon = maxlon, - service = "quarterlyData", - cbdate = cbdate, - cedate = cedate, - AQS_domain = AQS_domain - ) - - quarterlysummary <- purrr::pmap(.l = params, .f = aqs_services_by_box) - if (!return_header) quarterlysummary %<>% aqs_removeheader - return(quarterlysummary) -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/bycbsa.R b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/bycbsa.R deleted file mode 100644 index b036bc9..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/bycbsa.R +++ /dev/null @@ -1,336 +0,0 @@ -#' @section by_cbsa (By Core Based Statistical Area, as defined by the US Census Bureau) aggregate functions - - -#' @title aqs_monitors_by_cbsa -#' @description \lifecycle{stable} -#' Returns a table of monitors at all sites with the provided -#' parameter, aggregated by Core Based Statistical Area (CBSA) for -#' bdate - edate time frame. -#' @note All monitors that operated between the bdate and edate will be returned -#' @family Aggregate _by_cbsa functions -#' @inheritParams aqs_services_by_cbsa -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. If TRUE -#' returns a AQSAPI_v2 object which is a two item list -#' that contains header information returned from the -#' API server mostly used for debugging purposes in -#' addition to the data requested. -#' @examples # returns a tibble of $NO_{2}$ monitors -#' # for Charlotte-Concord-Gastonia, NC cbsa that were operating -#' # on Janurary 01, 2017 -#' \dontrun{aqs_monitors_by_cbsa(parameter="42602", -#' bdate=as.Date("20170101", -#' format="%Y%m%d"), -#' edate=as.Date("20170101", -#' format="%Y%m%d"), -#' cbsa_code="16740" -#' ) -#' } -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object that is the return value -#' from the AQS API. A AQS_Data Mart_APIv2 object is a 2 item named -#' list in which the first item ($Header) is a tibble of header -#' information from the AQS API and the second item ($Data) is a -#' tibble of the data returned. -#' @export -aqs_monitors_by_cbsa <- function(parameter, bdate, edate, cbsa_code, - cbdate = NA_Date_, cedate = NA_Date_, - return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, cbsa_code, cbdate, cedate, - return_header) - # aqs_monitors_by_* functions don't call aqsmultiyearparams() since the - # monitors API call accepts multiple years of data on the server, purrr::pmap - # is used so that the output is consistent with other RAQSAPI functions. - params <- tibble(parameter = parameter, - bdate = bdate, - edate = edate, - cbsa_code = cbsa_code, - service = "monitors", - cbdate = cbdate, - cedate = cedate) %>% - dplyr::select_if(function(x) {!all(is.na(x))}) - - monitors <- purrr::pmap(.l = params, .f = aqs_services_by_cbsa) - if (!return_header) monitors %<>% aqs_removeheader - return(monitors) -} - - -#' @title aqs_sampledata_by_cbsa -#' @description \lifecycle{stable} -#' Returns sample data where the data is aggregated at the Core -#' Based Statistical Area (cbsa) level. If return_header is -#' FALSE (default) this function returns a single dataframe with -#' the requested data. If return_header is TRUE returns a list -#' of AQSAPI_v2 objects where each index of the list is an -#' individual RAQSAPI_v2 object returned from each successive -#' call to the AQS API. RAQSAPI_v2 objects are two item list -#' where the $Data portion contains data that contains -#' sample air monitoring data at a site with the input -#' parameter and cbsa_code provided for -#' bdate - edate time frame. The $Header is a tibble of -#' header information from the API call /(useful for -#' debugging/). This function returns NULL is bdate > edate. -#' @note The AQS API only allows for a single year of sampledata to be retrieved -#' at a time. This function conveniently extracts date information from -#' the bdate and edate parameters then makes repeated calls to the -#' AQSAPI retrieving a maximum of one calendar year of data at a time. -#' Each calendar year of data requires a separate API call so multiple -#' years of data will require multiple API calls. As the number of years -#' of data being requested increases so does the length of time that it -#' will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. Fortunately this operation has a linear run time -#' /(Big O notation: O/(n + 5 seconds/)/) -#' @family Aggregate _by_cbsa functions -#' @inheritParams aqs_services_by_cbsa -#' @importFrom magrittr `%<>%` -#' @importFrom purrr pmap -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two item -#' list that contains header information returned from -#' the API server mostly used for debugging purposes in -#' addition to the data requested. -#' @return a tibble or an AQS_Data_Mart_APIv2 S3 object containing sample data -#' for all monitors matching cbsa_code for the given parameter. An -#' AQS_Data Mart_APIv2 is a 2 item named list in which the first item -#' /(/$Header/) is a tibble of header information from the AQS API and -#' the second item /(/$Data/) is a tibble of the data returned. -#' @examples # returns tibble which contains $NO_{2}$ data -#' # for Charlotte-Concord-Gastonia, NC cbsa for -#' # Janurary 1, 2015 - Janurary 01, 2017 -#' \dontrun{aqs_sampledata_by_cbsa(parameter = "42602", -#' bdate = as.Date("20150101", -#' format = "%Y%m%d"), -#' edate = as.Date("20170101", -#' format = "%Y%m%d"), -#' cbsa_code = "16740" -#' ) -#' } -#' @export -aqs_sampledata_by_cbsa <- function(parameter, bdate, edate, cbsa_code, - duration = NA_character_, - cbdate = NA_Date_, cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, cbsa_code, duration, cbdate, - cedate, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - cbsa_code = cbsa_code, - duration = duration, - service = "sampleData", - cbdate = cbdate, - cedate = cedate - ) - - sampledata <- purrr::pmap(.l = params, .f = aqs_services_by_cbsa) - if (!return_header) sampledata %<>% aqs_removeheader - return(sampledata) -} - - -#' @title aqs_annualsummary_by_cbsa -#' @description \lifecycle{stable} -#' Returns multiple years of data where annual data is -#' aggregated at the Core Based Statistical Area (CBSA) level. -#' Returned is an annual summary -#' matching the input parameter, and cbsa_code -#' provided for bdate - edate time frame. Variables returned -#' include mean value, maxima, percentiles, and etc. If -#' return_header is FALSE (default) the object returned is a -#' tibble, if TRUE an AQS_API_v2 object. -#' @note The AQS API only allows for a single year of annualsummary to be -#' retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_cbsa functions -#' @inheritParams aqs_services_by_cbsa -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. If TRUE -#' returns a AQSAPI_v2 object which is a two item list that contains header -#' information returned from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object that containing annual -#' summary data for the cbsa_code requested. A AQS_Data Mart_APIv2 is -#' a 2 item named list in which the first item ($Header) is a tibble -#' of header information from the AQS API and the second item ($Data) -#' is a tibble of the data returned. -#' @examples # Returns a tibble of annual summary $NO_{2}$ -#' # data the for Charlotte-Concord-Gastonia, NC cbsa on -#' # Janurary 01, 2017 -#' \dontrun{aqs_annualsummary_by_cbsa(parameter = "42602", -#' bdate = as.Date("20170101", -#' format = "%Y%m%d" -#' ), -#' edate = as.Date("20170101", -#' format = "%Y%m%d" -#' ), -#' cbsa_code = "16740" -#' ) -#' } -#' @export -aqs_annualsummary_by_cbsa <- function(parameter, bdate, edate, cbsa_code, - cbdate = NA_Date_, cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, cbsa_code, cbdate, cedate, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - cbsa_code = cbsa_code, - service = "annualData", - cbdate = cbdate, - cedate = cedate - ) - - annualsummary <- purrr::pmap(.l = params, .f = aqs_services_by_cbsa) - if (!return_header) annualsummary %<>% aqs_removeheader - return(annualsummary) - -} - - -#' @title aqs_dailysummary_by_cbsa -#' @description \lifecycle{stable} -#' Returns a tibble or an AQS_Data Mart_APIv2 S3 -#' object containing daily summary data aggregated by cbsa -#' (Core Based Statistical Area) code. -#' @note The AQS API only allows for a single year of dailysummary to be -#' retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_cbsa functions -#' @inheritParams aqs_services_by_cbsa -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. If TRUE -#' returns a AQSAPI_v2 object which is a two item list that contains header -#' information returned from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object that contains daily -#' summary statistics for the given parameter for a single cbsa_code. -#' An AQS_Data Mart_APIv2 is a 2 item named list in which the first -#' item ($Header) is a tibble of header information from the AQS API -#' and the second item ($Data) is a tibble of the data returned. -#' @examples # Returns a tibble of $NO_{2}$ daily summary -#' # data the for Charlotte-Concord-Gastonia, NC cbsa on -#' # Janurary 01, 2017 -#' \dontrun{aqs_dailysummary_by_cbsa(parameter = "42602", -#' bdate = as.Date("20170101", -#' format = "%Y%m%d" -#' ), -#' edate = as.Date("20190101", -#' format = "%Y%m%d" -#' ), -#' cbsa_code = "16740" -#' ) -#' } -#' @export -aqs_dailysummary_by_cbsa <- function(parameter, bdate, edate, cbsa_code, - cbdate = NA_Date_, cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, cbsa_code, cbdate, cedate, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - cbsa_code = cbsa_code, - service = "dailyData", - cbdate = cbdate, - cedate = cedate - ) - - dailysummary <- purrr::pmap(.l = params, .f = aqs_services_by_cbsa) - if (!return_header) dailysummary %<>% aqs_removeheader - return(dailysummary) -} - - -#' @title aqs_quarterlysummary_by_cbsa -#' @description \lifecycle{stable} -#' Returns a tibble or an AQS_Data Mart_APIv2 S3 -#' object of quarterly summary data aggregated by stateFIPS. -#' @note The AQS API only allows for a single year of quarterly summary to be -#' retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' -#' Also Note that for quarterly data, only the year portion of the bdate -#' and edate are used and all 4 quarters in the year are returned. -#' @family Aggregate _by_state functions -#' @inheritParams aqs_services_by_cbsa -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object that contains quarterly -#' summary statistics for the given parameter for a stateFIPS. -#' An AQS_Data Mart_APIv2 is a 2 item named list in which the first -#' item ($Header) is a tibble of header information from the AQS API -#' and the second item ($Data) is a tibble of the data returned. -#' @examples # Returns a tibble of $NO_{2}$ quartyerly summary -#' # data the for Charlotte-Concord-Gastonia, NC cbsa for -#' # each quarter in 2017. -#' \dontrun{aqs_quarterlysummary_by_cbsa(parameter = "42602", -#' bdate = as.Date("20170101", -#' format = "%Y%m%d"), -#' edate = as.Date("20171231", -#' format = "%Y%m%d"), -#' cbsa_code = "16740" -#' ) -#' } -#' @export -aqs_quarterlysummary_by_cbsa <- function(parameter, bdate, edate, cbsa_code, - cbdate = NA_Date_, cedate = NA_Date_, - return_header = FALSE) -{ - AQS_domain <- "aqs.epa.gov" - checkaqsparams(parameter, bdate, edate, cbsa_code, cbdate, cedate, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - cbsa_code = cbsa_code, - service = "quarterlyData", - cbdate = cbdate, - cedate = cedate, - AQS_domain = AQS_domain - ) - - quarterlysummary <- purrr::pmap(.l = params, .f = aqs_services_by_cbsa) - if (!return_header) quarterlysummary %<>% aqs_removeheader - return(quarterlysummary) -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/bycounty.R b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/bycounty.R deleted file mode 100644 index c05fa49..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/bycounty.R +++ /dev/null @@ -1,935 +0,0 @@ -#' @section by_county aggregate functions - -#' @title aqs_monitors_by_county -#' @description \lifecycle{stable} -#' Returns a table of monitors and related metadata at sites with the -#' provided parameter, stateFIPS and county_code for -#' bdate - edate time frame. -#' @note All monitors that operated between the bdate and edate will be returned -#' @family Aggregate _by_county functions -#' @inheritParams aqs_services_by_county -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two item -#' list that contains header information returned from -#' the API server mostly used for debugging purposes in -#' addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object of monitors from a -#' selected county -#' @examples # returns an aqs_v2 S3 object containing all SO2 monitors in -#' # Hawaii County, HI that were operating between May 01-02, 2015. -#' \dontrun{aqs_monitors_by_county(parameter="42401", -#' bdate=as.Date("20150501", format="%Y%m%d"), -#' edate=as.Date("20150502", format="%Y%m%d"), -#' stateFIPS="15", -#' countycode="001" -#' ) -#' } -#' @export -aqs_monitors_by_county <- function(parameter, bdate, edate, stateFIPS, - countycode, - cbdate = NA_Date_, cedate = NA_Date_, - return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, - cbdate, cedate, return_header) - - # aqs_monitors_by_* functions don't call aqsmultiyearparams() since the - # monitors API call accepts multiple years of data on the server, purrr::pmap - # is used so that the output is consistent with other RAQSAPI functions. - params <- tibble(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - service = "monitors", - cbdate = cbdate, - cedate = cedate) %>% - dplyr::select_if(function(x) {!all(is.na(x))}) - - monitors <- purrr::pmap(.l = params, .f = aqs_services_by_county) - if (!return_header) monitors %<>% aqs_removeheader - return(monitors) -} - - -#' @title aqs_sampledata_by_county -#' @description \lifecycle{stable} -#' Returns a single tibble with the requested data. If -#' return_header is TRUE returns a list -#' of AQSAPI_v2 objects where each index of the list is an -#' individual RAQSAPI_v2 object returned from each successive -#' call to the AQS API. RAQSAPI_v2 objects are two item list -#' where the $Data portion contains data that contains -#' sample air monitoring data at a site with the input -#' parameter, stateFIPS and county_code provided for -#' bdate - edate time frame. The $Header is a tibble of -#' header information from the API call /(useful for -#' debugging/). This function returns NULL is bdate > edate. -#' @note The AQS API only allows for a single year of sampledata to be retrieved -#' at a time. This function conveniently extracts date information from -#' the bdate and edate parameters then makes repeated calls to the -#' AQSAPI retrieving a maximum of one calendar year of data at a time. -#' Each calendar year of data requires a separate API call so multiple -#' years of data will require multiple API calls. As the number of years -#' of data being requested increases so does the length of time that it -#' will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_county functions -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two item -#' list that contains header information returned from -#' the API server mostly used for debugging purposes in -#' addition to the data requested. -#' @inheritParams aqs_services_by_county -#' @importFrom magrittr `%<>%` -#' @importFrom purrr pmap -#' @return a tibble or an AQS_Data_Mart_APIv2 S3 object containing sample data -#' for all monitors matching stateFIPS and county_code for the given -#' parameter. An AQS_Data Mart_APIv2 is a 2 item named list in which -#' the first item /(/$Header/) is a tibble of header information from -#' the AQS API and the second item /(/$Data/) is a tibble of the data -#' returned. -#' @examples # returns all FRM/FEM PM2.5 data for Wake County, NC between -#' # January 1, 2015 - February 28, 2016 -#' \dontrun{aqs_sampledata_by_county(parameter = "88101", -#' bdate = as.Date("20150101", -#' format = "%Y%m%d"), -#' edate=as.Date("20160228", -#' format = "%Y%m%d"), -#' stateFIPS = "37", -#' countycode = "183" -#' ) -#' } -#' @export -aqs_sampledata_by_county <- function(parameter, bdate, edate, stateFIPS, - countycode, - duration = NA_character_, - cbdate = NA_Date_, cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, - duration, cbdate, cedate, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - duration = duration, - service = "sampleData", - cbdate = cbdate, - cedate = cedate - ) - - sampledata <- purrr::pmap(.l = params, .f = aqs_services_by_county) - if (!return_header) sampledata %<>% aqs_removeheader - return(sampledata) -} - - -#' @title aqs_annualsummary_by_county -#' @description \lifecycle{stable} -#' Returns multiple years of data where annual data is -#' aggregated at the county level. Returned is an annual summary -#' matching the input parameter, stateFIPS, and county_code -#' provided for bdate - edate time frame. Variables -#' returned include mean value, maxima, percentiles, and etc. If -#' return_header is FALSE (default) the object returned is a -#' tibble, if TRUE an AQS_API_v2 object. -#' @note The AQS API only allows for a single year of annualsummary to be -#' retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_county functions -#' @inheritParams aqs_services_by_county -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. If -#' TRUE returns a AQSAPI_v2 object which is a two item -#' list that contains header information returned from -#' the API server mostly used for debugging purposes in -#' addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object that containing annual -#' summary data for the countycode and stateFIPS requested. -#' A AQS_Data Mart_APIv2 is a 2 item named list in which the first -#' item ($Header) is a tibble of header information from the AQS API -#' and the second item ($Data) is a tibble of the data returned. -#' @examples # returns an aqs S3 object with annual summary FRM/FEM -#' # PM2.5 data for Wake County, NC between January -#' # and February 2016 -#' \dontrun{aqs_annualsummary_by_county(parameter = "88101", -#' bdate = as.Date("20160101", -#' format = "%Y%m%d"), -#' edate = as.Date("20180228", -#' format = "%Y%m%d"), -#' stateFIPS = "37", -#' countycode = "183" -#' ) -#' } -#' @export -aqs_annualsummary_by_county <- function(parameter, bdate, edate, stateFIPS, - countycode, cbdate = NA_Date_, - cedate = NA_Date_, return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, - cbdate, cedate, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - service = "annualData", - cbdate = cbdate, - cedate = cedate - ) - - dailysummary <- purrr::pmap(.l = params, .f = aqs_services_by_county) - if (!return_header) dailysummary %<>% aqs_removeheader - return(dailysummary) -} - - -#' @title aqs_qa_blanks_by_county -#' @description \lifecycle{stable} -#' Returns a table of blank quality assurance data. -#' Blanks are unexposed sample collection devices (e.g., -#' filters) that are transported with the exposed sample devices -#' to assess if contamination is occurring during the transport -#' or handling of the samples. Data is aggregated at the county level. -#' @note The AQS API only allows for a single year of qa_blank data to be -#' retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_county functions -#' @inheritParams aqs_services_by_county -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. If -#' TRUE returns a AQSAPI_v2 object which is a two item -#' list that contains header information returned from -#' the API server mostly used for debugging purposes in -#' addition to the data requested. -#' @return a tibble or an AQS_Data_Mart_APIv2 S3 object that contains quality -#' assurance blank sample data for all monitors within the input -#' stateFIPS and countycode. An AQS_Data_Mart_APIv2 is a 2 item named -#' list in which the first item ($Header) is a tibble of header -#' information from the AQS API and the second item ($Data) is a -#' tibble of the data returned. -#' @examples # returns a tibble with PM2.5 blank data for -#' # Colbert County, AL for January 2018 -#' \dontrun{aqs_qa_blanks_by_county(parameter = "88101", -#' bdate = as.Date("20170101", -#' format="%Y%m%d"), -#' edate = as.Date("20190131", -#' format="%Y%m%d"), -#' stateFIPS = "01", -#' countycode = "033" -#' ) -#' } -#' @export -aqs_qa_blanks_by_county <- function(parameter, bdate, edate, stateFIPS, - countycode, cbdate = NA_Date_, - cedate = NA_Date_, return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, - cbdate, cedate, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - service = "qaBlanks", - cbdate = cbdate, - cedate = cedate - ) - - blanks <- purrr::pmap(.l = params, .f = aqs_services_by_county) - if (!return_header) blanks %<>% aqs_removeheader - return(blanks) -} - - -#' @title aqs_dailysummary_by_county -#' @description \lifecycle{stable} -#' Returns multiple years of data where daily data is -#' aggregated at the site level. Returned is a daily summary -#' matching the input parameter, stateFIPS and county_code -#' provided for bdate - edate time frame. Variables returned include -#' mean value, maxima, percentiles, and etc. -#' @note The AQS API only allows for a single year of dailysummary to be -#' retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_county functions -#' @inheritParams aqs_services_by_county -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object that contains daily -#' summary statistics for the given parameter for a single countycode -#' and stateFIPS combination. An AQS_Data Mart_APIv2 is a 2 item named -#' list in which the first item ($Header) is a tibble of header -#' information from the AQS API and the second item ($Data) is a -#' tibble of the data returned. -#' @examples # returns an aqs S3 object of daily summary FRM/FEM PM2.5 data -#' # for Wake County, NC between January and February 2016 -#' \dontrun{aqs_dailysummary_by_county(parameter = "88101", -#' bdate = as.Date("20160101", -#' format = "%Y%m%d"), -#' edate = as.Date("20170228", -#' format = "%Y%m%d"), -#' stateFIPS = "37", -#' countycode = "183" -#' ) -#' } -#' @export -aqs_dailysummary_by_county <- function(parameter, bdate, edate, stateFIPS, - countycode, cbdate = NA_Date_, - cedate = NA_Date_, return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, - cbdate, cedate, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - service = "dailyData", - cbdate = cbdate, - cedate = cedate - ) - - dailysummary <- purrr::pmap(.l = params, .f = aqs_services_by_county) - if (!return_header) dailysummary %<>% aqs_removeheader - return(dailysummary) -} - - -#' @title aqs_qa_collocated_assessments_by_county -#' @description \lifecycle{stable} -#' Returns a table of collocated assessment data aggregated by -#' matching input parameter, stateFIPS and county_code provided -#' for bdate - edate time frame. -#' @note The AQS API only allows for a single year of collocated assessments -#' data to be retrieved at a time. This function conveniently extracts -#' date information from the bdate and edate parameters then makes -#' repeated calls to the AQSAPI retrieving a maximum of one calendar -#' year of data at a time. Each calendar year of data requires a -#' separate API call so multiple years of data will require multiple API -#' calls. As the number of years of data being requested increases so -#' does the length of time that it will take to retrieve results. There -#' is also a 5 second wait time inserted between successive API calls to -#' prevent overloading the API server. This operation has a linear run -#' time of /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_county functions -#' @inheritParams aqs_services_by_county -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. If TRUE -#' returns a AQSAPI_v2 object which is a two item -#' list that contains header information returned from -#' the API server mostly used for debugging purposes in -#' addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -#' assurance collocated assessment data for monitors within a county. -#' An AQS_Data Mart_APIv2 is a 2 item named list in which the first -#' item ($Header) is a tibble of header information from the AQS API -#' and the second item ($Data) is a tibble of the data returned. -#' @examples # Returns a tibble with collocated assessment data -#' # for FRM PM2.5 in Madison County, AL for January 2015 -#' \dontrun{aqs_qa_collocated_assessments_by_county(parameter = "88101", -#' bdate = as.Date("20150101", -#' format = "%Y%m%d" -#' ), -#' edate = as.Date("20150131", -#' format = "%Y%m%d" -#' ), -#' stateFIPS = "01", -#' countycode = "089" -#' ) -#' } -#' @export -aqs_qa_collocated_assessments_by_county <- function(parameter, bdate, edate, - stateFIPS, countycode, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, - cbdate, cedate, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - service = "qaCollocatedAssessments", - cbdate = cbdate, - cedate = cedate - ) - - colocatedsummary <- purrr::pmap(.l = params, .f = aqs_services_by_county) - if (!return_header) colocatedsummary %<>% aqs_removeheader - return(colocatedsummary) -} - - -#' @title aqs_qa_flowrateverification_by_county -#' @description \lifecycle{stable} -#' Returns a table containing flow rate Verification data for a -#' parameter code aggregated matching input parameter, stateFIPS, -#' and county_code, provided for bdate - edate time frame. -#' @note The AQS API only allows for a single year of flow rate verifications to -#' be retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_county functions -#' @inheritParams aqs_services_by_county -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -#' assurance flow rate verification data for monitors within a county. -#' An AQS_Data Mart_APIv2 is a 2 item named list in which the first -#' item ($Header) is a tibble of header information from the AQS API -#' and the second item ($Data) is a tibble of the data returned. -#' @examples # returns a tibble of flow rate verification data for -#' # Colbert County, AL for January 2018 -#' \dontrun{aqs_qa_flowrateverification_by_county(parameter = "88101", -#' bdate = as.Date("20180101", -#' format = "%Y%m%d" -#' ), -#' edate = as.Date("20190131", -#' format = "%Y%m%d" -#' ), -#' stateFIPS = "01", -#' countycode = "033" -#' ) -#' } -#' @export -aqs_qa_flowrateverification_by_county <- function(parameter, bdate, edate, - stateFIPS, countycode, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, - cbdate, cedate, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - service = "qaFlowRateVerifications", - cbdate = cbdate, - cedate = cedate - ) - - frv <- purrr::pmap(.l = params, .f = aqs_services_by_county) - if (!return_header) frv %<>% aqs_removeheader - return(frv) -} - - -#' @title aqs_qa_flowrateaudit_by_county -#' @description \lifecycle{stable} -#' Returns a table containing flow rate audit -#' data aggregated by parameter code, stateFIPS and countycode -#' for bdate - edate time frame. -#' @note The AQS API only allows for a single year of flow rate audit data to -#' be retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_county functions -#' @inheritParams aqs_services_by_county -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing flow rate -#' audit data for the requested countycode and stateFIPS. An -#' AQS_Data_Mart_APIv2 object is a 2 item named list in which the -#' first item ($Header) is a tibble of header information from the -#' AQS API and the second item ($Data) is a tibble of the data -#' returned. -#' @examples #Returns a tibble of flow rate audit data for -#' # Jefferson County, AL for January 2018 -#' \dontrun{aqs_qa_flowrateaudit_by_county(parameter = "88101", -#' bdate = as.Date("20170101", -#' format="%Y%m%d"), -#' edate = as.Date("20190131", -#' format = "%Y%m%d"), -#' tateFIPS = "01", -#' countycode = "073" -#' ) -#' } -#' @export -aqs_qa_flowrateaudit_by_county <- function(parameter, bdate, edate, stateFIPS, - countycode, cbdate = NA_Date_, - cedate = NA_Date_, return_header - ) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, - cbdate, cedate, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - service = "qaFlowRateAudits", - cbdate = cbdate, - cedate = cedate - ) - - fra <- purrr::pmap(.l = params, .f = aqs_services_by_county) - if (!return_header) fra %<>% aqs_removeheader - return(fra) -} - - -#' @title aqs_qa_one_point_qc_by_county_ -#' @description \lifecycle{stable} -#' Returns a tibble or an AQS_Data Mart_APIv2 S3 object -#' containing one point QC check data aggregated by county_code. -#' @note The AQS API only allows for a single year of one point qc data to -#' be retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_county functions -#' @inheritParams aqs_services_by_county -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. If TRUE -#' returns a AQSAPI_v2 object which is a two item -#' list that contains header information returned from -#' the API server mostly used for debugging purposes in -#' addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing one point -#' qc data within a county. A AQS_Data_Mart_APIv2 object is a -#' 2 item named list in which the first item ($Header) is a tibble -#' of header information from the AQS API and the second item -#' ($Data) is a tibble of the data returned. -#' @examples #returns a tibble of One Point QC data for ozone -#' # in Barnstable County, MA for January 2018 -#' \dontrun{aqs_qa_one_point_qc_by_county(parameter= "44201", -#' bdate = as.Date("20170101", -#' format = "%Y%m%d"), -#' edate = a s.Date("20180131", -#' format = "%Y%m%d"), -#' stateFIPS = "25", -#' countycode = "001" -#' ) -#' } -#' @export -aqs_qa_one_point_qc_by_county <- function(parameter, bdate, edate, stateFIPS, - countycode, cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, - cbdate, cedate, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - service = "qaOnePointQcRawData", - cbdate = cbdate, - cedate = cedate - ) - - opqcc <- purrr::pmap(.l = params, .f = aqs_services_by_county) - if (!return_header) opqcc %<>% aqs_removeheader - return(opqcc) -} - - -#' @title aqs_qa_pep_audit_by_county -#' @description \lifecycle{stable} -#' Returns a table of Performance Evaluation Program (PEP) audit -#' data aggregated by parameter code, stateFIPS and countycode -#' for the time frame between bdate and edate. -#' @note The AQS API only allows for a single year of pep audit data -#' to be retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_county functions -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. If TRUE -#' returns a AQSAPI_v2 object which is a two item -#' list that contains header information returned from -#' the API server mostly used for debugging purposes in -#' addition to the data requested. -#' @inheritParams aqs_services_by_county -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -#' assurance PEP audit data within a county. A AQS_Data_Mart_APIv2 -#' object is a 2 item named list in which the first item ($Header) is -#' a tibble of header information from the AQS API and the second item -#' ($Data) is a tibble of the data returned. -#' @examples # returns a tibble with PEP Audit data for FRM -#' # PM2.5 in Madison County, AL for 2017 -#' \dontrun{aqs_qa_pep_audit_by_county_multiyear(parameter = "88101", -#' bdate = as.Date("20150101", -#' format = "%Y%m%d" -#' ), -#' edate = as.Date("20171231", -#' format = "%Y%m%d" -#' ), -#' stateFIPS = "01", -#' countycode = "089" -#' ) -#' } -#' @export -aqs_qa_pep_audit_by_county <- function(parameter, bdate, edate, stateFIPS, - countycode, cbdate = NA_Date_, - cedate = NA_Date_, return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, - cbdate, cedate, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - service = "qaPepAudits", - cbdate = cbdate, - cedate = cedate - ) - - pepaudit <- purrr::pmap(.l = params, .f = aqs_services_by_county) - if (!return_header) pepaudit %<>% aqs_removeheader - return(pepaudit) -} - - -#' @title aqs_transactionsample_by_county -#' @description \lifecycle{stable} -#' Returns transactionsample data - aggregated by county -#' in the AQS Submission Transaction Format (RD) sample (raw) data -#' for a parameter code aggregated by matching input parameter, -#' stateFIPS and countycode provided for bdate - edate time frame. -#' Includes data both in submitted and standard units -#' @note The AQS API only allows for a single year of transaction data to be -#' retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of -#' data at a time. Each calendar year of data requires a separate API -#' call so multiple years of data will require multiple API calls. -#' As the number of years of data being requested increases so does the -#' length of time that it will take to retrieve results. There is also a -#' 5 second wait time inserted between successive API calls to prevent -#' overloading the API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_county functions -#' @inheritParams aqs_services_by_county -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @importFrom magrittr `%<>%` -#' @examples -#' \dontrun{ # Returns all FRM/FEM transaction data for -#' # Wake County, NC between on Feb 28, 2016. -#' aqs_transactionsample_by_county(parameter = "88101", -#' bdate = as.Date("20160228", -#' format = "%Y%m%d"), -#' edate = as.Date("20160228", -#' format = "%Y%m%d"), -#' stateFIPS = "37", -#' countycode = "183" -#' ) -#' } -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object of transaction sample -#' (raw) data in the AQS submission transaction format (RD) -#' corresponding to the inputs provided. -#' @export -aqs_transactionsample_by_county <- function(parameter, bdate, edate, - stateFIPS, countycode, - return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - service = "transactionsSample" - ) - - transactionsample <- purrr::pmap(.l = params, .f = aqs_services_by_county) - if (!return_header) transactionsample %<>% aqs_removeheader - return(transactionsample) -} - - -#' @title aqs_qa_annualperformanceeval_by_county -#' @description \lifecycle{stable} -#' Returns AQS submissions transaction format (RD) of the annual -#' performance evaluation data (raw). Includes data pairs for -#' QA - aggregated by county for a parameter code aggregated by -#' matching input parameter, countycode and stateFIPS -#' provided for bdate - edate time frame. -#' @note The AQS API only allows for a single year of quality assurance -#' Annual Performance Evaluation data to be retrieved at a time. This -#' function conveniently extracts date information from the bdate -#' and edate parameters then makes repeated calls to the AQSAPI -#' retrieving a maximum of one calendar year of data at a time. Each -#' calendar year of data requires a separate API call so multiple years -#' of data will require multiple API calls. As the number of years of -#' data being requested increases so does the length of time that it -#' will take to retrieve results. There is also a 5 second wait time -#' inserted between successive API calls to prevent overloading the API -#' server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_county functions -#' @inheritParams aqs_services_by_county -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @importFrom magrittr `%<>%` -#' @examples # Returns a tibble containing annual performance evaluation data -#' # (raw) for ozone in Baldwin County, AL for 2017 in RD format. -#' \dontrun{ aqs_qa_annualperformanceeval_by_county(parameter = "44201", -#' bdate = as.Date("20170101", -#' format = "%Y%m%d"), -#' edate = as.Date("20171231", -#' format = "%Y%m%d"), -#' stateFIPS = "01", -#' countycode = "003" -#' ) -#' } -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object of quality assurance -#' performance evaluation data. for single monitoring site for the -#' sitenum, countycode and stateFIPS requested for the time frame -#' between bdate and edate. An AQS_Data_Mart_APIv2 is a 2 item named -#' list in which the first item ($Header) is a tibble of header -#' information from the AQS API and the second item ($Data) is a -#' tibble of the data returned. -#' @export -aqs_qa_annualperformanceeval_by_county <- function(parameter, bdate, - edate, stateFIPS, - countycode, - return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - service = "qaAnnualPerformanceEvaluations" - ) - - qaape <- purrr::pmap(.l = params, .f = aqs_services_by_county) - if (!return_header) qaape %<>% aqs_removeheader - return(qaape) -} - - -#' @title aqs_qa_annualperformanceevaltransaction_by_site -#' @description \lifecycle{stable} -#' Returns AQS submissions transaction format (RD) of the annual -#' performance evaluation data (raw). Includes data pairs for -#' QA - aggregated by site for a parameter code aggregated by matching -#' input parameter, countycode and stateFIPS provided for -#' bdate - edate time frame. -#' @note The AQS API only allows for a single year of quality assurance -#' Annual Performance Evaluations transaction data to be retrieved at a -#' time. This function conveniently extracts date information from the -#' bdate and edate parameters then makes repeated calls to the AQSAPI -#' retrieving a maximum of one calendar year of data at a time. Each -#' calendar year of data requires a separate API call so multiple years -#' of data will require multiple API calls. As the number of years of -#' data being requested increases so does the length of time that it -#' will take to retrieve results. There is also a 5 second wait time -#' inserted between successive API calls to prevent overloading the API -#' server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_site functions -#' @inheritParams aqs_services_by_county -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @importFrom magrittr `%<>%` -#' @examples # Returns a tibble containing annual performance evaluation data -#' # (raw) for ozone in Baldwin County, AL for 2017 in RD format. -#' \dontrun{aqs_qa_annualperformanceevaltransaction_by_county(parameter = "44201", -#' bdate = as.Date("20170101", -#' format = "%Y%m%d"), -#' edate = as.Date("20171231", -#' format = "%Y%m%d"), -#' stateFIPS = "01", -#' countycode = "003" -#' ) -#' } -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object of quality assurance -#' performance evaluation data in the RD format for a single -#' monitoring site for the countycode and stateFIPS requested -#' for the time frame between bdate and edate in the AQS. An -#' AQS_Data_Mart_APIv2 is a 2 item named list in which the first item -#' ($Header) is a tibble of header information from the AQS API and -#' the second item ($Data) is a tibble of the data returned. -#' @export -aqs_qa_annualperformanceevaltransaction_by_county <- function(parameter, bdate, - edate, stateFIPS, - countycode, - return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - service = "transactionsQaAnnualPerformanceEvaluations" - ) - - tqaape <- purrr::pmap(.l = params, .f = aqs_services_by_county) - if (!return_header) tqaape %<>% aqs_removeheader - return(tqaape) -} - - -#' @title aqs_quarterlysummary_by_county -#' @description \lifecycle{stable} -#' Returns a tibble or an AQS_Data Mart_APIv2 S3 -#' object of quarterly summary data aggregated by cbsa -#' (Core Based Statistical Area) code. -#' @note The AQS API only allows for a single year of quarterly summary to be -#' retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' -#' Also Note that for quarterly data, only the year portion of the bdate -#' and edate are used and all 4 quarters in the year are returned. -#' @family Aggregate _by_county functions -#' @inheritParams aqs_services_by_county -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object that contains quarterly -#' summary statistics for the given parameter for a single countycode -#' and stateFIPS combination. An AQS_Data Mart_APIv2 is a 2 item named -#' list in which the first item ($Header) is a tibble of header -#' information from the AQS API and the second item ($Data) is a -#' tibble of the data returned. -#' @examples # returns a tibble containing quarterly summaries for -#' # FRM/FEM PM2.5 data for Wake County, NC for each quarter of 2016 -#' \dontrun{aqs_quarterlysummary_by_county(parameter = "88101", -#' bdate = as.Date("20160101", -#' format = "%Y%m%d"), -#' edate = as.Date("20170228", -#' format = "%Y%m%d"), -#' stateFIPS = "37", -#' countycode = "183" -#' ) -#' } -#' @export -aqs_quarterlysummary_by_county <- function(parameter, bdate, edate, stateFIPS, - countycode, cbdate = NA_Date_, - cedate = NA_Date_, return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, - cbdate, cedate, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - service = "quarterlyData", - cbdate = cbdate, - cedate = cedate - ) - - quarterlysummary <- purrr::pmap(.l = params, .f = aqs_services_by_county) - if (!return_header) quarterlysummary %<>% aqs_removeheader - return(quarterlysummary) -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/byma.R b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/byma.R deleted file mode 100644 index aeab85f..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/byma.R +++ /dev/null @@ -1,588 +0,0 @@ -#' @section by_ma aggregate functions - - -#' @title aqs_qa_blanks_by_MA -#' @description \lifecycle{stable} -#' Returns a table of blank quality assurance data. -#' Blanks are unexposed sample collection devices (e.g., -#' filters) that are transported with the exposed sample devices -#' to assess if contamination is occurring during the transport -#' or handling of the samples. Data is aggregated by monitoring agency -#' code (MA_code). -#' @note The AQS API only allows for a single year of qa_blank data to be -#' retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_MA functions -#' @inheritParams aqs_services_by_MA -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. If TRUE -#' returns a AQSAPI_v2 object which is a two item list that contains header -#' information returned from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data_Mart_APIv2 S3 object that contains quality -#' assurance blank sample data for all monitors within the input -#' MA_code. An AQS_Data_Mart_APIv2 is a 2 item named -#' list in which the first item ($Header) is a tibble of header -#' information from the AQS API and the second item ($Data) is a -#' tibble of the data returned. -#' @examples # Returns a tibble containing PM2.5 blank data in -#' # January 2018 where the Monitoring Agency is the Alabama -#' # Department of Environmental Management (agency 0013) -#' \dontrun{aqs_qa_blanks_by_MA(parameter = "88101", -#' bdate = as.Date("20170101", -#' format = "%Y%m%d"), -#' edate = as.Date("20190131", -#' format = "%Y%m%d"), -#' MA_code = "0013" -#' ) -#' } -#' @export -aqs_qa_blanks_by_MA <- function(parameter, bdate, edate, MA_code, - cbdate = NA_Date_, cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, MA_code, cbdate, cedate, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - MA_code = MA_code, - service = "qaBlanks", - cbdate = cbdate, - cedate = cedate - ) - - blanks <- purrr::pmap(.l = params, .f = aqs_services_by_MA) - if (!return_header) blanks %<>% aqs_removeheader - return(blanks) -} - - -#' @title aqs_qa_collocated_assessments_by_MA -#' @description \lifecycle{stable} -#' Returns a table of collocated assessment data aggregated by -#' matching input parameter, and monitoring agency (MA) code -#' provided for bdate - edate time frame. -#' @note The AQS API only allows for a single year of collocated assessments -#' data to be retrieved at a time. This function conveniently extracts -#' date information from the bdate and edate parameters then makes -#' repeated calls to the AQSAPI retrieving a maximum of one calendar -#' year of data at a time. Each calendar year of data requires a -#' separate API call so multiple years of data will require multiple API -#' calls. As the number of years of data being requested increases so -#' does the length of time that it will take to retrieve results. There -#' is also a 5 second wait time inserted between successive API calls to -#' prevent overloading the API server. This operation has a linear run -#' time of /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_MA functions -#' @inheritParams aqs_services_by_MA -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. If TRUE -#' returns a AQSAPI_v2 object which is a two item list that contains header -#' information returned from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -#' assurance collocated assessment data for monitors within a -#' monitoring agency. An AQS_Data Mart_APIv2 is a 2 item named list -#' in which the first item ($Header) is a tibble of header information -#' from the AQS API and the second item ($Data) is a tibble of the -#' data returned. -#' @examples # Returns a tibble containing collocated assessment -#' # data for FRM PM2.5 January 2013 where the Monitoring Agency is -#' # the Alabama Department of Environmental Management -#' # (agency 0013) -#' \dontrun{aqs_qa_collocated_assessments_by_MA(parameter="88101", -#' bdate = as.Date("20130101", -#' format = "%Y%m%d"), -#' edate = as.Date("20150131", -#' format="%Y%m%d"), -#' MA_code = "0013" -#' ) -#' } -#' @export -aqs_qa_collocated_assessments_by_MA <- function(parameter, bdate, - edate, MA_code, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, MA_code, cbdate, cedate, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - MA_code = MA_code, - service = "qaCollocatedAssessments", - cbdate = cbdate, - cedate = cedate - ) - - colocatedsummary <- purrr::pmap(.l = params, .f = aqs_services_by_MA) - if (!return_header) colocatedsummary %<>% aqs_removeheader - return(colocatedsummary) -} - - -#' @title aqs_qa_flowrateverification_by_MA -#' @description \lifecycle{stable} -#' Returns a table containing flow rate Verification data for a -#' parameter code aggregated by matching input parameter, and -#' monitoring agency (MA) code provided for bdate - edate time -#' frame. -#' @note The AQS API only allows for a single year of flow rate verifications to -#' be retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_MA functions -#' @inheritParams aqs_services_by_MA -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. If TRUE -#' returns a AQSAPI_v2 object which is a two item list that contains header -#' information returned from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -#' assurance flow rate verification data for monitors within a -#' Monitoring agency. An AQS_Data Mart_APIv2 is a 2 item named list in -#' which the first item ($Header) is a tibble of header information -#' from the AQS API and the second item ($Data) is a tibble of the -#' data returned. -#' @examples -#' # Returns a tibble containing collocated assessment -#' # data for FRM PM2.5 January 2013 where the Monitoring Agency is -#' # the Alabama Department of Environmental Management (agency 0013) -#' \dontrun{aqs_qa_flowrateverification_by_MA(parameter = "88101", -#' bdate = as.Date("20130101", -#' format = "%Y%m%d" -#' ), -#' edate = as.Date("20150131", -#' format = "%Y%m%d" -#' ), -#' MA_code = "0013" -#' ) -#' } -#' @export -aqs_qa_flowrateverification_by_MA <- function(parameter, bdate, edate, - MA_code, cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, MA_code, cbdate, cedate, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - MA_code = MA_code, - service = "qaFlowRateVerifications", - cbdate = cbdate, - cedate = cedate - ) - - frv <- purrr::pmap(.l = params, .f = aqs_services_by_MA) - if (!return_header) frv %<>% aqs_removeheader - return(frv) -} - - -#' @title aqs_qa_flowrateaudit_by_MA -#' @description \lifecycle{stable} -#' Returns a table containing flow rate audit -#' data aggregated by parameter code and monitoring agency code -#' (_by_MA) for bdate - edate time frame. -#' @note The AQS API only allows for a single year of flow rate audit data to -#' be retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_MA functions -#' @inheritParams aqs_services_by_MA -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. If TRUE -#' returns a AQSAPI_v2 object which is a two item list that contains header -#' information returned from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing flow rate -#' audit data for the requested MA_code. An -#' AQS_Data_Mart_APIv2 object is a 2 item named list in which the -#' first item ($Header) is a tibble of header information from the -#' AQS API and the second item ($Data) is a tibble of the data -#' returned. -#' @examples -#' # returns a tibble of flow rate audit data -#' # for FRM PM2.5 January 2016 - Januray 2018 where the Monitoring Agency is -#' # the Jefferson County, AL Department of Health (agency 0550) -#' \dontrun{aqs_qa_flowrateaudit_by_MA(parameter = "88101", -#' bdate = as.Date("20160101", -#' format = "%Y%m%d"), -#' edate = as.Date("20180131", -#' format = "%Y%m%d"), -#' MA_code = "0550" -#' ) -#' } -#' @export -aqs_qa_flowrateaudit_by_MA <- function(parameter, bdate, edate, MA_code, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, MA_code, cbdate, cedate, - return_header) - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - MA_code = MA_code, - service = "qaFlowRateAudits", - cbdate = cbdate, - cedate = cedate - ) - - fra <- purrr::pmap(.l = params, .f = aqs_services_by_MA) - if (!return_header) fra %<>% aqs_removeheader - return(fra) -} - - -#' @title aqs_qa_one_point_qc_by_MA -#' @description \lifecycle{stable} -#' Returns a tibble or an AQS_Data Mart_APIv2 S3 object -#' containing one point QC check data aggregated by monitoring -#' agency code (_by_MA). -#' @note The AQS API only allows for a single year of one point qc data to -#' be retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_MA functions -#' @inheritParams aqs_services_by_MA -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. If TRUE -#' returns a AQSAPI_v2 object which is a two item list that contains header -#' information returned from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing one point -#' qc data for a single monitoring agency. A AQS_Data_Mart_APIv2 -#' object is a 2 item named list in which the first item ($Header) -#' is a tibble of header information from the AQS API and the second -#' item ($Data) is a tibble of the data returned. -#' @examples # returns a tibble of ozone One Point QC data -#' # in January 2018 where the Monitoring Agency is the -#' # Massachusetts Department of Environmental Protection -#' # (agency 0660) -#' \dontrun{aqs_qa_one_point_qc_by_MA(parameter = "44201", -#' bdate = as.Date("20170101", -#' format = "%Y%m%d"), -#' edate = as.Date("20180131", -#' format = "%Y%m%d"), -#' MA_code = "0660" -#' ) -#' } -#' @export -aqs_qa_one_point_qc_by_MA <- function(parameter, bdate, edate, MA_code, - cbdate = NA_Date_, cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, MA_code, cbdate, cedate, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - MA_code = MA_code, - service = "qaOnePointQcRawData", - cbdate = cbdate, - cedate = cedate - ) - - opqcc <- purrr::pmap(.l = params, .f = aqs_services_by_MA) - if (!return_header) opqcc %<>% aqs_removeheader - return(opqcc) -} - - -#' @title aqs_qa_pep_audit_by_MA -#' @description \lifecycle{stable} -#' Returns a table of Performance Evaluation Program (PEP) audit -#' data aggregated by monitoring agency code (_by_MA) for the -#' time frame between bdate and edate. -#' @note The AQS API only allows for a single year of one point pep audit data -#' to be retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_MA functions -#' @inheritParams aqs_services_by_MA -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. If TRUE -#' returns a AQSAPI_v2 object which is a two item list that contains header -#' information returned from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -#' assurance PEP audit data for a monitoring agency. A -#' AQS_Data_Mart_APIv2 object is a 2 item named list in which the -#' first item ($Header) is a tibble of header information from the -#' AQS API and the second item ($Data) is a tibble of the data -#' returned. -#' @examples # Returns a tibble of PEP audit data for -#' # June 2017 where the Monitoring Agency is the Alabama Department -#' # of Environmental Management (agency 0013) -#' \dontrun{aqs_qa_pep_audit_by_MA(parameter = "88101", -#' bdate = as.Date("20170601", -#' format = "%Y%m%d"), -#' edate = as.Date("20170630", -#' format = "%Y%m%d"), -#' MA_code = "0013" -#' ) -#' } -#' @export -aqs_qa_pep_audit_by_MA <- function(parameter, bdate, edate, MA_code, - cbdate = NA_Date_, cedate = NA_Date_, - return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, MA_code, cbdate, cedate, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - MA_code = MA_code, - service = "qaPepAudits", - cbdate = cbdate, - cedate = cedate - ) - - pepaudit <- purrr::pmap(.l = params, .f = aqs_services_by_MA) - if (!return_header) pepaudit %<>% aqs_removeheader - return(pepaudit) -} - - -#' @title aqs_transactionsample_MA -#' @description \lifecycle{stable} -#' Returns transactionsample data - aggregated by Monitoring agency (MA) -#' in the AQS Submission Transaction Format (RD) sample (raw) data for -#' a parameter code aggregated by matching input parameter, and -#' monitoring agency (MA) code provided for bdate - edate time -#' frame. Includes data both in submitted and standard units -#' -#' @note The AQS API only allows for a single year of transaction data to be -#' retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of -#' data at a time. Each calendar year of data requires a separate API -#' call so multiple years of data will require multiple API calls. -#' As the number of years of data being requested increases so does the -#' length of time that it will take to retrieve results. There is also a -#' 5 second wait time inserted between successive API calls to prevent -#' overloading the API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_state functions -#' @inheritParams aqs_services_by_MA -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @importFrom magrittr `%<>%` -#' @examples #Returns a tibble of ozone transaction sample data for all monitors -#' #operated by South Coast Air Quality Management District collected -#' #on May 15, 2015 -#' \dontrun{aqs_transactionsample_by_MA(parameter = "44201", -#' bdate = as.Date("20150515", -#' format = "%Y%m%d"), -#' edate = as.Date("20150515", -#' format = "%Y%m%d"), -#' MA_code = "0972" -#' ) -#' } -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object of transaction sample -#' (raw) data in the AQS submission transaction format (RD) -#' corresponding to the inputs provided. -#' @export -aqs_transactionsample_by_MA <- function(parameter, bdate, edate, MA_code, - cbdate = NA_Date_, cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, MA_code, cbdate, cedate, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - MA_code = MA_code, - service = "transactionsSample" - ) - - transactionsample <- purrr::pmap(.l = params, .f = aqs_services_by_MA) - if (!return_header) transactionsample %<>% aqs_removeheader - return(transactionsample) -} - - -#' @title aqs_qa_annualperformanceeval_by_MA -#' @description \lifecycle{stable} -#' Returns quality assurance performance evaluation data - aggregated by -#' by Monitoring agency (MA) for a parameter -#' code aggregated by matching input parameter and MA_code for the -#' time frame between bdate and edate. -#' @note The AQS API only allows for a single year of quality assurance -#' Annual Performance Evaluation data to be retrieved at a time. This -#' function conveniently extracts date information from the bdate -#' and edate parameters then makes repeated calls to the AQSAPI -#' retrieving a maximum of one calendar year of data at a time. Each -#' calendar year of data requires a separate API call so multiple years -#' of data will require multiple API calls. As the number of years of -#' data being requested increases so does the length of time that it -#' will take to retrieve results. There is also a 5 second wait time -#' inserted between successive API calls to prevent overloading the API -#' server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_MA functions -#' @inheritParams aqs_services_by_MA -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @importFrom magrittr `%<>%` -#' @examples -#' # Returns a tibble containing annual performance evaluation data -#' # for ozone where the monitoring agency is the Alabama Department -#' # of Environmental Management (MA_code 0013). -#' \dontrun{aqs_qa_annualperformanceeval_by_MA(parameter = "44201", -#' bdate = as.Date("20170101", -#' format = "%Y%m%d"), -#' edate = as.Date("20171231", -#' format = "%Y%m%d"), -#' MA_code = "0013" -#' ) -#' } -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object of quality assurance -#' performance evaluation data. for all monitoring sites for with -#' the MA_code requested for the time frame between bdate and edate. -#' An AQS_Data_Mart_APIv2 is a 2 item named list in which the first -#' item ($Header) is a tibble of header information from the AQS API -#' and the second item ($Data) is a tibble of the data returned. -#' @export -aqs_qa_annualperformanceeval_by_MA <- function(parameter, bdate, edate, - MA_code, - return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, MA_code, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - MA_code = MA_code, - service = "qaAnnualPerformanceEvaluations" - ) - - qaape <- purrr::pmap(.l = params, .f = aqs_services_by_MA) - if (!return_header) qaape %<>% aqs_removeheader - return(qaape) -} - - -#' @title aqs_qa_annualperformanceevaltransaction_by_MA -#' @description \lifecycle{stable} -#' Returns AQS submissions transaction format (RD) of the annual -#' performance evaluation data (raw). Includes data pairs for -#' QA - aggregated by Monitoring agency (MA) -#' for a parameter code aggregated by matching input parameter and -#' MA_code provided for bdate - edate time frame. -#' @note The AQS API only allows for a single year of quality assurance -#' Annual Performance Evaluations transaction data to be retrieved at a -#' time. This function conveniently extracts date information from the -#' bdate and edate parameters then makes repeated calls to the AQSAPI -#' retrieving a maximum of one calendar year of data at a time. Each -#' calendar year of data requires a separate API call so multiple years -#' of data will require multiple API calls. As the number of years of -#' data being requested increases so does the length of time that it -#' will take to retrieve results. There is also a 5 second wait time -#' inserted between successive API calls to prevent overloading the API -#' server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_MA functions -#' @inheritParams aqs_services_by_MA -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @importFrom magrittr `%<>%` -#' @examples # Returns a tibble containing annual performance evaluation data -#' # for ozone in where the MA is the Alabama Department of -#' # Environmental Management (MA_code 0013) for 2017 in RD format. -#' \dontrun{aqs_qa_annualperformanceevaltransaction_by_MA(parameter = "44201", -#' bdate = as.Date("20170101", -#' format = "%Y%m%d"), -#' edate = as.Date("20171231", -#' format = "%Y%m%d"), -#' MA_code = "0013" -#' ) -#' } -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object of quality assurance -#' performance evaluation data in the AQS submissions transaction -#' format (RD)for all sites matching the MA_code requested for the -#' time frame between bdate and edate. An AQS_Data_Mart_APIv2 is a 2 -#' item named list in which the first item ($Header) is a tibble of -#' header information from the AQS API and the second item ($Data) is -#' a tibble of the data returned. -#' @export -aqs_qa_annualperformanceevaltransaction_by_MA <- function(parameter, bdate, - edate, MA_code, - return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, MA_code, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - MA_code = MA_code, - service = - "transactionsQaAnnualPerformanceEvaluations" - ) - - tqaape <- purrr::pmap(.l = params, .f = aqs_services_by_MA) - if (!return_header) tqaape %<>% aqs_removeheader - return(tqaape) -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/bypqao.R b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/bypqao.R deleted file mode 100644 index 178d1d7..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/bypqao.R +++ /dev/null @@ -1,524 +0,0 @@ -#' @section by_pqao aggregate functions - -#' @title aqs_qa_blanks_by_pqao -#' @description \lifecycle{stable} -#' Returns a table of blank quality assurance data. -#' Blanks are unexposed sample collection devices (e.g., -#' filters) that are transported with the exposed sample devices -#' to assess if contamination is occurring during the transport -#' or handling of the samples. Data is aggregated by -#' Primary Quality Assurance Organization (PQAO). -#' @note The AQS API only allows for a single year of flow rate audit data to -#' be retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_pqao functions -#' @inheritParams aqs_services_by_pqao -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. If TRUE -#' returns a AQSAPI_v2 object which is a two item list that contains header -#' information returned from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -#' assurance blank data for monitors within a pqao. An -#' AQS_Data Mart_APIv2 is a 2 item named list in which the first item -#' ($Header) is a tibble of header information from the AQS API and -#' the second item ($Data) is a tibble of the data returned. -#' @examples # Returns tibble of PM2.5 blank data in -#' # January 2018 where the PQAO is the Alabama Department of -#' # Environmental Management (agency 0013) -#' \dontrun{aqs_qa_blanks_by_pqao(parameter = "88101", -#' bdate = as.Date("20180101", -#' format = "%Y%m%d"), -#' edate = as.Date("20180131", -#' format = "%Y%m%d"), -#' pqao_code = "0013" -#' ) -#' } -#' @export -aqs_qa_blanks_by_pqao <- function(parameter, bdate, edate, pqao_code, - cbdate = NA_Date_, cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, pqao_code, cbdate, cedate, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - pqao_code = pqao_code, - service = "qaBlanks", - cbdate = cbdate, - cedate = cedate - ) - - blanks <- purrr::pmap(.l = params, .f = aqs_services_by_pqao) - if (!return_header) blanks %<>% aqs_removeheader - return(blanks) -} - - -#' @title aqs_qa_collocated_assessments_by_pqao -#' @description \lifecycle{stable} -#' Returns a table of collocated assessment data aggregated by -#' matching input parameter, and Primary Quality Assurance -#' Organisation (PQAO) code provided for bdate - edate -#' time frame. -#' @note The AQS API only allows for a single year of collocated assessments -#' data to be retrieved at a time. This function conveniently extracts -#' date information from the bdate and edate parameters then makes -#' repeated calls to the AQSAPI retrieving a maximum of one calendar -#' year of data at a time. Each calendar year of data requires a -#' separate API call so multiple years of data will require multiple API -#' calls. As the number of years of data being requested increases so -#' does the length of time that it will take to retrieve results. There -#' is also a 5 second wait time inserted between successive API calls to -#' prevent overloading the API server. This operation has a linear run -#' time of /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_pqao functions -#' @inheritParams aqs_services_by_pqao -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. If TRUE -#' returns a AQSAPI_v2 object which is a two item list that contains header -#' information returned from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -#' assurance collocated assessment data for monitors within a pqao. -#' An AQS_Data Mart_APIv2 is a 2 item named list in which the first -#' item ($Header) is a tibble of header information from the AQS API -#' and the second item ($Data) is a tibble of the data returned. -#' @examples # Returns a tibble of collocated assessment -#' # data for FRM PM2.5 in January 2013 where the PQAO is the Alabama -#' # Department of Environmental Management (agency 0013) -#' \dontrun{aqs_qa_collocated_assessments_by_pqao(parameter = "88101", -#' bdate = as.Date("20130101", -#' format = "%Y%m%d"), -#' edate = as.Date("20150131", -#' format = "%Y%m%d"), -#' pqao_code = "0013" -#' ) -#' } -#' @export -aqs_qa_collocated_assessments_by_pqao <- function(parameter, bdate, edate, - pqao_code, cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, pqao_code, cbdate, cedate, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - pqao_code = pqao_code, - service = "qaCollocatedAssessments", - cbdate = cbdate, - cedate = cedate - ) - - colocatedsummary <- purrr::pmap(.l = params, .f = aqs_services_by_pqao) - if (!return_header) colocatedsummary %<>% aqs_removeheader - return(colocatedsummary) -} - - -#' @title aqs_qa_flowrateverification_by_pqao -#' @description \lifecycle{stable} -#' Returns a table containing flow rate Verification data for a -#' parameter code aggregated by matching input parameter, and -#' Primary Quality Assurance Organization (PQAO) code provided -#' for bdate - edate time. -#' @note The AQS API only allows for a single year of flow rate verifications to -#' be retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_pqao functions -#' @inheritParams aqs_services_by_pqao -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. If TRUE -#' returns a AQSAPI_v2 object which is a two item list that contains header -#' information returned from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -#' assurance flow rate verification data for monitors within a pqao. -#' An AQS_Data Mart_APIv2 is a 2 item named list in which the first -#' item ($Header) is a tibble of header information from the AQS API -#' and the second item ($Data) is a tibble of the data returned. -#' @examples # returns a tibble of flow rate verification -#' # data for January 2018 where the PQAO is the Alabama Department -#' # of Environmental Management (agency 0013) -#' \dontrun{aqs_qa_flowrateverification_by_pqao(parameter = "88101", -#' bdate = as.Date("20170101", -#' format = "%Y%m%d" -#' ), -#' edate = as.Date("20190131", -#' format = "%Y%m%d" -#' ), -#' pqao_code = "0013" -#' ) -#' } -#' @export -aqs_qa_flowrateverification_by_pqao <- function(parameter, bdate, edate, - pqao_code, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, pqao_code, cbdate, cedate, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - pqao_code = pqao_code, - service = "qaFlowRateVerifications", - cbdate = cbdate, - cedate = cedate - ) - - frv <- purrr::pmap(.l = params, .f = aqs_services_by_pqao) - if (!return_header) frv %<>% aqs_removeheader - return(frv) -} - - -#' @title aqs_qa_flowrateaudit_by_pqao -#' @description \lifecycle{stable} -#' Returns a table containing flow rate audit -#' data aggregated by parameter code and Primary Quality -#' Assurance Organization (PQAO) code for bdate - edate -#' time frame. -#' @note The AQS API only allows for a single year of flow rate audit data to -#' be retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_pqao functions -#' @inheritParams aqs_services_by_pqao -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. If TRUE -#' returns a AQSAPI_v2 object which is a two item list that contains header -#' information returned from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing flow rate -#' audit data for the requested pqao_code. An -#' AQS_Data_Mart_APIv2 object is a 2 item named list in which the -#' first item ($Header) is a tibble of header information from the -#' AQS API and the second item ($Data) is a tibble of the data -#' returned. -#' @examples # Returns a tibble of flow rate audit data for January -#' # 2018 where the PQAO is the Jefferson County, AL Department of -#' # Health (agency 0550). -#' \dontrun{aqs_qa_flowrateaudit_by_pqao(parameter = "88101", -#' bdate = as.Date("20170101", -#' format = "%Y%m%d"), -#' edate = as.Date("20180131", -#' format = "%Y%m%d"), -#' pqao_code = "0550" -#' ) -#' } -#' @export -aqs_qa_flowrateaudit_by_pqao <- function(parameter, bdate, edate, pqao_code, - cbdate = NA_Date_, cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, pqao_code, cbdate, cedate, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - pqao_code = pqao_code, - service = "qaFlowRateAudits", - cbdate = cbdate, - cedate = cedate - ) - - fra <- purrr::pmap(.l = params, .f = aqs_services_by_pqao) - if (!return_header) fra %<>% aqs_removeheader - return(fra) -} - - -#' @title aqs_qa_one_point_qc_by_pqao -#' @description \lifecycle{stable} -#' Returns a tibble or an AQS_Data Mart_APIv2 S3 object containing Quality -#' assurance data - collocated assessment raw data aggregated by Primary -#' Quality Assurance Organization (PQAO) code. -#' @note The AQS API only allows for a single year of one point qc data to -#' be retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_pqao functions -#' @inheritParams aqs_services_by_pqao -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. If TRUE -#' returns a AQSAPI_v2 object which is a two item list that contains header -#' information returned from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing one point -#' qc data within a pqao. A AQS_Data_Mart_APIv2 object is a -#' 2 item named list in which the first item ($Header) is a tibble -#' of header information from the AQS API and the second item -#' @examples -#' # returns a tibble of ozone One Point QC -#' # data for Jan 2017 - January 2018 where the PQAO is the Massachusetts -#' # Department of Environmental Protection (agency 0660) -#' \dontrun{aqs_qa_one_point_qc_by_pqao(parameter = "88101", -#' bdate = as.Date("20170101", -#' format = "%Y%m%d"), -#' edate = as.Date("20180131", -#' format = "%Y%m%d"), -#' pqao_code = "0660" -#' ) -#' } -#' @export -aqs_qa_one_point_qc_by_pqao <- function(parameter, bdate, edate, pqao_code, - cbdate = NA_Date_, cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, pqao_code, cbdate, cedate, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - pqao_code = pqao_code, - service = "qaOnePointQcRawData", - cbdate = cbdate, - cedate = cedate - ) - - opqcc <- purrr::pmap(.l = params, .f = aqs_services_by_pqao) - if (!return_header) opqcc %<>% aqs_removeheader - return(opqcc) -} - - -#' @title aqs_qa_pep_audit_by_pqao -#' @description \lifecycle{stable} -#' Returns a table of Performance Evaluation Program (PEP) audit -#' data aggregated by Primary Quality Assurance Organization -#' (PQAO) code for the time frame between bdate and edate. -#' @note The AQS API only allows for a single year of pep audit data -#' to be retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_pqao functions -#' @inheritParams aqs_services_by_pqao -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. If TRUE -#' returns a AQSAPI_v2 object which is a two item list that contains header -#' information returned from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -#' assurance PEP audit data for a Primary Quality Assurance -#' Organization. A AQS_Data_Mart_APIv2 object is a 2 item named list -#' in which the first item ($Header) is a tibble of header -#' information from the AQS API and the second item ($Data) is a -#' tibble of the data returned. -#' @examples # returns a tibble of PEP audit data for -#' # June 2017 where the pqao is the Alabama Department of -#' # Environmental Management (agency 0013) -#' \dontrun{aqs_qa_pep_audit_by_pqao(parameter = "88101", -#' bdate = as.Date("20170601", -#' format = "%Y%m%d" -#' ), -#' edate = as.Date("20190630", -#' format = "%Y%m%d"), -#' pqao_code = "0013" -#' ) -#' } -#' @export -aqs_qa_pep_audit_by_pqao <- function(parameter, bdate, edate, pqao_code, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, pqao_code, cbdate, cedate, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - pqao_code = pqao_code, - service = "qaPepAudits", - cbdate = cbdate, - cedate = cedate - ) - - pepaudit <- purrr::pmap(.l = params, .f = aqs_services_by_pqao) - if (!return_header) pepaudit %<>% aqs_removeheader - return(pepaudit) -} - - -#' @title aqs_qa_annualperformanceeval_by_pqao -#' @description \lifecycle{stable} -#' Returns quality assurance performance evaluation data - aggregated by -#' Primary Quality Assurance Organization (PQAO) for a parameter -#' code aggregated by matching input parameter and pqao_code for the -#' time frame between bdate and edate. -#' @note The AQS API only allows for a single year of quality assurance -#' Annual Performance Evaluation data to be retrieved at a time. This -#' function conveniently extracts date information from the bdate -#' and edate parameters then makes repeated calls to the AQSAPI -#' retrieving a maximum of one calendar year of data at a time. Each -#' calendar year of data requires a separate API call so multiple years -#' of data will require multiple API calls. As the number of years of -#' data being requested increases so does the length of time that it -#' will take to retrieve results. There is also a 5 second wait time -#' inserted between successive API calls to prevent overloading the API -#' server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_pqao functions -#' @inheritParams aqs_services_by_pqao -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @importFrom magrittr `%<>%` -#' @examples # Returns a tibble containing annual performance evaluation data -#' # for ozone where the PQAO is the Alabamaba Department of -#' # Environmental Management (pqao_code 0013). -#' \dontrun{ aqs_qa_annualperformanceeval_by_pqao(parameter = "44201", -#' bdate = as.Date("20170101", -#' format = "%Y%m%d"), -#' edate = as.Date("20171231", -#' format = "%Y%m%d"), -#' pqao_code = "0013" -#' ) -#' } -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object of quality assurance -#' performance evaluation data. for single monitoring site for the -#' pqao_code requested for the time frame -#' between bdate and edate. An AQS_Data_Mart_APIv2 is a 2 item named -#' list in which the first item ($Header) is a tibble of header -#' information from the AQS API and the second item ($Data) is a -#' tibble of the data returned. -#' @export -aqs_qa_annualperformanceeval_by_pqao <- function(parameter, bdate, edate, - pqao_code, - return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, pqao_code, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - pqao_code = pqao_code, - service = "qaAnnualPerformanceEvaluations" - ) - - qaape <- purrr::pmap(.l = params, .f = aqs_services_by_pqao) - if (!return_header) qaape %<>% aqs_removeheader - return(qaape) -} - - -#' @title aqs_qa_annualperformanceevaltransaction_by_pqao -#' @description \lifecycle{stable} -#' Returns AQS submissions transaction format (RD) of the annual -#' performance evaluation data (raw). Includes data pairs for -#' QA - aggregated by Primary Quality Assurance Organization (PQAO) -#' for a parameter code aggregated by matching input parameter and -#' pqao_code provided for bdate - edate time frame. -#' @note The AQS API only allows for a single year of quality assurance -#' Annual Performance Evaluations transaction data to be retrieved at a -#' time. This function conveniently extracts date information from the -#' bdate and edate parameters then makes repeated calls to the AQSAPI -#' retrieving a maximum of one calendar year of data at a time. Each -#' calendar year of data requires a separate API call so multiple years -#' of data will require multiple API calls. As the number of years of -#' data being requested increases so does the length of time that it -#' will take to retrieve results. There is also a 5 second wait time -#' inserted between successive API calls to prevent overloading the API -#' server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_pqao functions -#' @inheritParams aqs_services_by_pqao -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @importFrom magrittr `%<>%` -#' @examples #Returns a tibble containing annual performance evaluation data for -#' # ozone in where the PQAO is the Alabama Department of -#' # Environmental Management (pqao_code 0013) for 2017 in RD format. -#' \dontrun{aqs_qa_annualperformanceevaltransaction_by_pqao(parameter = -#' "44201", -#' bdate = as.Date("20170101", -#' format = "%Y%m%d"), -#' edate = as.Date("20171231", -#' format = "%Y%m%d"), -#' pqao_code = "0013" -#' ) -#' } -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object of quality assurance -#' performance evaluation data. for single monitoring site for the -#' sitenum, countycode and stateFIPS requested for the time frame -#' between bdate and edate. An AQS_Data_Mart_APIv2 is a 2 item named -#' list in which the first item ($Header) is a tibble of header -#' information from the AQS API and the second item ($Data) is a -#' tibble of the data returned. -#' @export -aqs_qa_annualperformanceevaltransaction_by_pqao <- function(parameter, - bdate, edate, - pqao_code, - return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, pqao_code, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - pqao_code = pqao_code, - service = "transactionsQaAnnualPerformanceEvaluations" - ) - - tqaape <- purrr::pmap(.l = params, .f = aqs_services_by_pqao) - if (!return_header) tqaape %<>% aqs_removeheader - return(tqaape) -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/bysite.R b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/bysite.R deleted file mode 100644 index c9a54bd..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/bysite.R +++ /dev/null @@ -1,1018 +0,0 @@ -#' @section by_site aggregate functions - - -#' @title aqs_monitors_by_site -#' @description \lifecycle{stable} -#' Returns a table of monitors and related metadata at sites with the -#' provided parameter, stateFIPS, county_code, and sitenum for -#' bdate - edate time frame. -#' @note All monitors that operated between the bdate and edate will be returned -#' @family Aggregate _by_site functions -#' @inheritParams aqs_services_by_site -#' @importFrom magrittr `%<>%` -#' @importFrom tibble tibble -#' @importFrom dplyr select_if -#' @importFrom purrr pmap -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object of monitors from a -#' selected stateFIPS, county, and sitenum combination. -#' @examples -#' #Returns a tibble of the SO2 monitors at Hawaii -#' # Volcanoes NP site (\#0007) in Hawaii County, HI that were operating -#' # between May 1 , 2015-2019. (Note, all monitors that operated between the -#' # bdate and edate will be returned). -#' \dontrun{ -#' aqs_monitors_by_site(parameter = "42401", -#' bdate = as.Date("20150501", -#' format="%Y%m%d"), -#' edate = as.Date("20190501", -#' format="%Y%m%d"), -#' stateFIPS = "15", -#' countycode = "001", -#' sitenum = "0007" -#' ) -#' } -#' -#' @export -aqs_monitors_by_site <- function(parameter, bdate, edate, stateFIPS, - countycode, sitenum, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, cbdate, cedate, - return_header) - # aqs_monitors_by_* functions don't call aqsmultiyearparams() since the - # monitors API call accepts multiple years of data on the server, purrr::pmap - # is used so that the output is consistent with other RAQSAPI functions. - params <- tibble(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - service = "monitors", - sitenum = sitenum, - cbdate = cbdate, - cedate = cedate) %>% - dplyr::select_if(function(x) {!all(is.na(x))}) - - monitors <- purrr::pmap(.l = params, .f = aqs_services_by_site) - if (!return_header) monitors %<>% aqs_removeheader - return(monitors) -} - - -#' @title aqs_qa_flowrate audit_by_site -#' @description \lifecycle{stable} -#' Returns a table containing flow rate audit -#' data aggregated by parameter code, stateFIPS, countycode and -#' site number for bdate - edate time frame. -#' @inheritParams aqs_services_by_site -#' @importFrom magrittr `%<>%` -#' @note The AQS API only allows for a single year of flow rate audit data to -#' be retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_site functions -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing flow rate -#' audit data for the requested sitenum, countycode and stateFIPS. An -#' AQS_Data_Mart_APIv2 object is a 2 item named list in which the -#' first item ($Header) is a tibble of header information from the -#' AQS API and the second item ($Data) is a tibble of the data -#' returned. -#' @examples # returns a tibble of flow rate audit data -#' # for the Wylam site (#2003) in Jefferson County, AL -#' # for January 2018: -#' \dontrun{aqs_qa_flowrateaudit_by_site(parameter = "88101", -#' bdate = as.Date("20150101", -#' format="%Y%m%d"), -#' edate = as.Date("20180131", -#' format="%Y%m%d"), -#' stateFIPS = "01", -#' countycode = "073", -#' sitenum = "2003" -#' ) -#' } -#' @export -aqs_qa_flowrateaudit_by_site <- function(parameter, bdate, edate, - stateFIPS, countycode, - sitenum, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, sitenum, - cbdate, cedate) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - sitenum = sitenum, - service = "qaFlowRateAudits", - cbdate = cbdate, - cedate = cedate - ) - - fra <- purrr::pmap(.l = params, .f = aqs_services_by_site) - if (!return_header) fra %<>% aqs_removeheader - return(fra) -} - - -#' @title aqs_qa_one_point_qc_by_site -#' @description \lifecycle{stable} -#' Returns a table of one point QC raw data -#' aggregated by parameter code, stateFIPS, countycode and -#' site number. -#' @note The AQS API only allows for a single year of one point qc data to -#' be retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_site functions -#' @inheritParams aqs_services_by_site -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing one point -#' qc data for the requested site. A AQS_Data_Mart_APIv2 object is a -#' 2 item named list in which the first item ($Header) is a tibble -#' of header information from the AQS API and the second item -#' ($Data) is a tibble of the data returned. -#' @examples # returns a tibbble of One Point QC data for -#' # ozone at the Truro National Seashore site (\#0002) in -#' # Barnstable County, MA for January 2018: -#' \dontrun{aqs_qa_one_point_qc_by_site(parameter = "44201", -#' bdate = as.Date("20180101", -#' format = "%Y%m%d"), -#' edate = as.Date("20180131", -#' format = "%Y%m%d"), -#' stateFIPS = "25", -#' countycode = "001", -#' sitenum = "0002" -#' ) -#' } -#' @export -aqs_qa_one_point_qc_by_site <- function(parameter, bdate, edate, - stateFIPS, countycode, - sitenum, cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, sitenum, - cbdate, cedate, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - sitenum = sitenum, - service = "qaOnePointQcRawData", - cbdate = cbdate, - cedate = cedate - ) - - opqcc <- purrr::pmap(.l = params, .f = aqs_services_by_site) - if (!return_header) opqcc %<>% aqs_removeheader - return(opqcc) -} - - -#' @title aqs_qa_pep_audit_by_site -#' @description \lifecycle{stable} -#' Returns a table of Performance Evaluation Program (PEP) audit -#' data aggregated by parameter code, stateFIPS, countycode and -#' site number for the time frame between bdate and edate. -#' @note The AQS API only allows for a single year of pep audit data -#' to be retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_site functions -#' @inheritParams aqs_services_by_site -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -#' assurance PEP audit data within a site. A AQS_Data_Mart_APIv2 -#' object is a 2 item named list in which the first item ($Header) is -#' a tibble of header information from the AQS API and the second item -#' ($Data) is a tibble of the data returned. -#' @examples # returns a tibble of pep Audit data for FRM PM2.5 -#' # at the Huntsville Old Airport site (\#0014) in Madison County, -#' # AL for 2017 - 2019. -#' \dontrun{aqs_qa_pep_audit_by_site(parameter = "88101", -#' bdate = as.Date("20170101", -#' format = "%Y%m%d"), -#' edate = as.Date("20191231", -#' format = "%Y%m%d"), -#' stateFIPS = "01", -#' countycode = "089", -#' sitenum = "0014" -#' ) -#' } -#' @export -aqs_qa_pep_audit_by_site <- function(parameter, bdate, edate, - stateFIPS, countycode, sitenum, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, sitenum, - cbdate, cedate, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - sitenum = sitenum, - service = "qaPepAudits", - cbdate = cbdate, - cedate = cedate - ) - - pepaudit <- purrr::pmap(.l = params, .f = aqs_services_by_site) - if (!return_header) pepaudit %<>% aqs_removeheader - return(pepaudit) -} - - -#' @title aqs_sampledata_by_site -#' @description \lifecycle{stable} -#' Returns multiple years of data where sample data is -#' aggregated at the site level. If return_header is -#' FALSE (default) returns a single data frame with -#' the requested data. If return_header is TRUE returns a list -#' of AQSAPI_v2 objects where each index of the list is an -#' individual RAQSAPI_v2 object returned from each successive -#' calls to the AQS API. RAQSAPI_v2 objects are two item list -#' where the $Data portion contains data that contains -#' sample air monitoring data at a site with the input -#' parameter, stateFIPS and county_code provided for -#' bdate - edate time frame. The $Header is a tibble of -#' header information from the API call /(useful for -#' debugging/). Returns NULL is bdate > edate. -#' @note The AQS API only allows for a single year of sampledata to be retrieved -#' at a time. This function conveniently extracts date information from -#' the bdate and edate parameters then makes repeated calls to the -#' AQSAPI retrieving a maximum of one calendar year of data at a time. -#' Each calendar year of data requires a separate API call so multiple -#' years of data will require multiple API calls. As the number of years -#' of data being requested increases so does the length of time that it -#' will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_site functions -#' @inheritParams aqs_services_by_site -#' @param return_header If FALSE (default) returns a single data frame with the -#' data requested. If TRUE returns a AQSAPI_v2 object -#' which is a two item list that contains header -#' information returned from the API server mostly used -#' for debugging purposes in addition to the data -#' requested. This is mostly useful for debugging -#' purposes, in case the user wishes to see the header -#' information from each api call. -#' @importFrom magrittr `%>%` `%<>%` -#' @importFrom purrr pmap -#' @return a tibble or an AQS_Data_Mart_APIv2 S3 object containing sample data -#' for a single site with the input parameter. An AQS_Data Mart_APIv2 -#' is a 2 item named list in which the first item /(/$Header/) is a -#' tibble of header information from the AQS API and the second item -#' /(/$Data/) is a tibble of the data returned. -#' @examples #Returns a table of ozone monitoring data for the Millbrook School -#' # site (/#0014) in Wake County, NC for June 18, 2017. -#' \dontrun{ -#' aqs_sampledata_by_site(parameter = "44201", -#' bdate = as.Date("20170618", -#' format = "%Y%m%d"), -#' edate = as.Date("20190618", -#' format = "%Y%m%d"), -#' stateFIPS = "37", -#' countycode = "183", -#' sitenum = "0014" -#' ) -#' } -#' @export -aqs_sampledata_by_site <- function(parameter, bdate, edate, stateFIPS, - countycode, sitenum, - duration = NA_character_, - cbdate = NA_Date_, cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, sitenum, - duration, cbdate, cedate, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - sitenum = sitenum, - duration = duration, - service = "sampleData", - cbdate = cbdate, - cedate = cedate - ) - - sampledata <- purrr::pmap(.l = params, .f = aqs_services_by_site) - if (!return_header) sampledata %<>% aqs_removeheader - return(sampledata) -} - - -#' @title aqs_annualsummary_by_site -#' @description \lifecycle{stable} -#' Returns multiple years of data where annual data is -#' aggregated at the site level. Returned is an annual summary -#' matching the input parameter, stateFIPS, county_code, and -#' sitenum provided for bdate - edate time frame. The data -#' returned is summarized at the annual level. Variables -#' returned include mean value, maxima, percentiles, and etc. If -#' return_header is FALSE (default) the object returned is a -#' tibble, if TRUE an AQS_API_v2 object. -#' @note The AQS API only allows for a single year of annualsummary to be -#' retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_site functions -#' @inheritParams aqs_services_by_site -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested as a -#' single tibble. If TRUE returns a list of AQSAPI_v2 -#' objects which is a two item list that contains header -#' information returned from the API server mostly used -#' for debugging purposes in addition to the data -#' requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing annual -#' summary data for the sitenum, countycode and stateFIPS requested. -#' A AQS_Data Mart_APIv2 is a 2 item named list in which the first -#' item ($Header) is a tibble of header information from the AQS API -#' and the second item ($Data) is a tibble of the data returned. -#' @examples # Returns a tibble of annual summary ozone -#' # data for the Millbrook School site (\#0014) in Wake County, -#' # NC for 2017 (Note, for annual data, only the -#' # year portion of the bdate and edate are used and only whole -#' # years of data are returned. For example, bdate = 2017-12-31 and -#' # edate = 2018-01-01 will return full data for 2017 and 2018 ) -#' \dontrun{ -#' aqs_annualsummary_by_site(parameter = "44201", -#' bdate = as.Date("20170618", -#' format="%Y%m%d"), -#' edate = as.Date("20190618", -#' format="%Y%m%d"), -#' stateFIPS = "37", -#' countycode = "183", -#' sitenum = "0014" -#' ) -#' } -#' @export -aqs_annualsummary_by_site <- function(parameter, bdate, edate, stateFIPS, - countycode, sitenum, cbdate = NA_Date_, - cedate = NA_Date_, return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, sitenum, - cbdate, cedate, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - sitenum = sitenum, - service = "annualData", - cbdate = cbdate, - cedate = cedate - ) - - annualdata <- purrr::pmap(.l = params, .f = aqs_services_by_site) - if (!return_header) annualdata %<>% aqs_removeheader - return(annualdata) -} - - -#' @title aqs_qa_blanks_by_site -#' @description \lifecycle{stable} -#' Returns a table of blank quality assurance data. -#' Blanks are unexposed sample collection devices (e.g., -#' filters) that are transported with the exposed sample devices -#' to assess if contamination is occurring during the transport -#' or handling of the samples. Data is aggregated at the site level. -#' @note The AQS API only allows for a single year of qa_blank data to be -#' retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_site functions -#' @inheritParams aqs_services_by_site -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data_Mart_APIv2 S3 object that contains quality -#' assurance blank sample data for single monitoring site for the -#' sitenum, countycode and stateFIPS requested for the time frame -#' between bdate and edate. An AQS_Data_Mart_APIv2 is a 2 item named -#' list in which the first item ($Header) is a tibble of header -#' information from the AQS API and the second item ($Data) is a -#' tibble of the data returned. -#' @examples #Returns a tibble of PM2.5 blank -#' # data for the Muscle Shoals site (#0014) in Colbert County, AL -#' # for January 2018 -#' \dontrun{ -#' aqs_qa_blanks_by_site(parameter = "88101", -#' bdate = as.Date("20170101", -#' format="%Y%m%d"), -#' edate = as.Date("20190131", -#' format="%Y%m%d"), -#' stateFIPS = "01", -#' countycode = "033", -#' sitenum = "1002" -#' ) -#' } -#' @export -aqs_qa_blanks_by_site <- function(parameter, bdate, edate, stateFIPS, - countycode, sitenum, cbdate = NA_Date_, - cedate = NA_Date_, return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, sitenum, - cbdate, cedate, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - sitenum = sitenum, - service = "qaBlanks", - cbdate = cbdate, - cedate = cedate - ) - - blanks <- purrr::pmap(.l = params, .f = aqs_services_by_site) - if (!return_header) blanks %<>% aqs_removeheader - return(blanks) -} - - -#' @title aqs_dailysummary_by_site -#' @description \lifecycle{stable} -#' Returns multiple years of data where dailysummary data is -#' aggregated at the site level. Returned is a daily summary -#' matching the input parameter stateFIPS, countycode, and sitenum -#' provided for bdate - edate time frame. Data is aggregated at the -#' state level. Variables returned include mean value, maxima, -#' percentiles, and etc. -#' @note The AQS API only allows for a single year of dailysummary to be -#' retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_site functions -#' @inheritParams aqs_services_by_site -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object that contains daily -#' summary statistics for the given parameter for a single site. An -#' AQS_Data Mart_APIv2 is a 2 item named list in which the first item -#' ($Header) is a tibble of header information from the AQS API and -#' the second item ($Data) is a tibble of the data returned. -#' @examples #Returns a tibble of daily summary ozone -#' # data for the Millbrook School site (\#0014) in Wake County, -#' # NC for June 18, 2017. -#' \dontrun{ -#' aqs_dailysummary_by_site(parameter = "44201", -#' bdate = as.Date("20160618", -#' format = "%Y%m%d"), -#' edate = as.Date("20190618", -#' format = "%Y%m%d"), -#' stateFIPS = "37", -#' countycode = "183", -#' sitenum = "0014" -#' ) -#' } -#' @export -aqs_dailysummary_by_site <- function(parameter, bdate, edate, stateFIPS, - countycode, sitenum, cbdate = NA_Date_, - cedate = NA_Date_, return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, sitenum, - cbdate, cedate, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - sitenum = sitenum, - service = "dailyData", - cbdate = cbdate, - cedate = cedate - ) - - dailysummary <- purrr::pmap(.l = params, .f = aqs_services_by_site) - if (!return_header) dailysummary %<>% aqs_removeheader - return(dailysummary) -} - - -#' @title aqs_qa_collocated_assessments_by_site -#' @description \lifecycle{stable} -#' Returns a table of collocated assessment data aggregated by -#' matching input parameter, stateFIPS, county_code, and -#' sitenum provided for bdate - edate time frame. -#' @note The AQS API only allows for a single year of collocated assessments -#' data to be retrieved at a time. This function conveniently extracts -#' date information from the bdate and edate parameters then makes -#' repeated calls to the AQSAPI retrieving a maximum of one calendar -#' year of data at a time. Each calendar year of data requires a -#' separate API call so multiple years of data will require multiple API -#' calls. As the number of years of data being requested increases so -#' does the length of time that it will take to retrieve results. There -#' is also a 5 second wait time inserted between successive API calls to -#' prevent overloading the API server. This operation has a linear run -#' time of /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_site functions -#' @inheritParams aqs_services_by_site -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -#' assurance collocated assessment data for monitors within a site. -#' An AQS_Data Mart_APIv2 is a 2 item named list in which the first -#' item ($Header) is a tibble of header information from the AQS API -#' and the second item ($Data) is a tibble of the data returned. -#' @examples #returns a tibble of collocated assessment data -#' # for FRM PM2.5 at the Huntsville Old Airport site (\#0014) -#' # in Madison County, AL for January 2015: -#' \dontrun{aqs_qa_collocated_assessments_by_site(parameter = "88101", -#' bdate = as.Date("20150101", -#' format = "%Y%m%d" -#' ), -#' edate = as.Date("20150131", -#' format = "%Y%m%d" -#' ), -#' stateFIPS = "01", -#' countycode = "089", -#' sitenum = "0014" -#' ) -#' } -#' @export -aqs_qa_collocated_assessments_by_site <- function(parameter, bdate, edate, - stateFIPS, countycode, - sitenum, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, sitenum, - cbdate, cedate, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - sitenum = sitenum, - service = "qaCollocatedAssessments", - cbdate = cbdate, - cedate = cedate - ) - - colocatedsummary <- purrr::pmap(.l = params, .f = aqs_services_by_site) - if (!return_header) colocatedsummary %<>% aqs_removeheader - return(colocatedsummary) -} - - -#' @title aqs_qa_flowrateverification_by_site -#' @description \lifecycle{stable} -#' Returns a table containing flow rate Verification data for a -#' parameter code aggregated matching input parameter, stateFIPS, -#' county_code, and sitenum provided for -#' bdate - edate time frame. -#' @note The AQS API only allows for a single year of flow rate verifications to -#' be retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_site functions -#' @inheritParams aqs_services_by_site -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -#' assurance flow rate verification data for monitors at a site. -#' An AQS_Data Mart_APIv2 is a 2 item named list in which the first -#' item ($Header) is a tibble of header information from the AQS API -#' and the second item ($Data) is a tibble of the data returned. -#' @examples # returns a tibble of flow rate verification -#' # data for the Muscle Shoals site (#1002) in Colbert County, AL -#' # for January 2018: -#' \dontrun{aqs_qa_flowrateverification_by_site(parameter = "88101", -#' bdate = as.Date("20170101", -#' format = "%Y%m%d"), -#' edate = as.Date("20180131", -#' format = "%Y%m%d"), -#' stateFIPS = "01", -#' countycode = "033", -#' sitenum = "1002" -#' ) -#' } -#' @export -aqs_qa_flowrateverification_by_site <- function(parameter, bdate, edate, - stateFIPS, countycode, sitenum, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, sitenum, - cbdate, cedate, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - sitenum = sitenum, - service = "qaFlowRateVerifications", - cbdate = cbdate, - cedate = cedate - ) - - frv <- purrr::pmap(.l = params, .f = aqs_services_by_site) - if (!return_header) frv %<>% aqs_removeheader - return(frv) -} - - -#' @title aqs_transactionsample_by_site -#' @description \lifecycle{stable} -#' Returns transactionsample data aggregated by site -#' in the AQS Submission Transaction Format (RD) sample (raw) data for -#' a parameter code aggregated by matching input parameter, sitenum, -#' countycode and stateFIPS provided for bdate - edate time frame. -#' Includes data both in submitted and standard units -#' @note The AQS API only allows for a single year of transaction data to be -#' retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of -#' data at a time. Each calendar year of data requires a separate API -#' call so multiple years of data will require multiple API calls. -#' As the number of years of data being requested increases so does the -#' length of time that it will take to retrieve results. There is also a -#' 5 second wait time inserted between successive API calls to prevent -#' overloading the API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_site functions -#' @inheritParams aqs_services_by_site -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @importFrom magrittr `%<>%` -#' @examples #Returns a AQS_Data Mart_APIv2 S3 object of the returns -#' \dontrun{ # returns all ozone transaction data for the -#' # Millbrook School site (#0014) in Wake County, NC for -#' # June 18, 2017 -#' aqs_transactionsample_by_site(parameter = "44201", -#' bdate = as.Date("20170618", -#' format = "%Y%m%d"), -#' edate = as.Date("20170618", -#' format = "%Y%m%d"), -#' stateFIPS = "37", -#' countycode = "183", -#' sitenum = "0014" -#' ) -#' } -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object of transaction sample -#' (raw) data in the AQS submission transaction format (RD) -#' corresponding to the inputs provided. -#' @export -aqs_transactionsample_by_site <- function(parameter, bdate, edate, - stateFIPS, countycode, sitenum, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, sitenum, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - sitenum = sitenum, - cbdate = cbdate, - cedate = cedate, - service = "transactionsSample" - ) - - transactionsample <- purrr::pmap(.l = params, .f = aqs_services_by_site) - if (!return_header) transactionsample %<>% aqs_removeheader - return(transactionsample) -} - - -#' @title aqs_qa_annualperformanceeval_by_site -#' @description \lifecycle{stable} -#' Returns quality assurance performance evaluation data - aggregated by -#' site for a parameter code aggregated by matching input -#' parameter, sitenum, countycode and stateFIPS provided for -#' bdate - edate time frame. -#' @note The AQS API only allows for a single year of quality assurance -#' Annual Performance Evaluation data to be retrieved at a time. This -#' function conveniently extracts date information from the bdate -#' and edate parameters then makes repeated calls to the AQSAPI -#' retrieving a maximum of one calendar year of data at a time. Each -#' calendar year of data requires a separate API call so multiple years -#' of data will require multiple API calls. As the number of years of -#' data being requested increases so does the length of time that it -#' will take to retrieve results. There is also a 5 second wait time -#' inserted between successive API calls to prevent overloading the API -#' server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_site functions -#' @inheritParams aqs_services_by_site -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @importFrom magrittr `%<>%` -#' @examples #Returns a tibble containing annual performance evaluation data for -#' # ozone at the Fairhope site in Baldwin County, AL for 2017 -#' \dontrun{ aqs_qa_annualperformanceeval_by_site(parameter = "44201", -#' bdate = as.Date("20170101", -#' format = "%Y%m%d"), -#' edate = as.Date("20171231", -#' format = "%Y%m%d"), -#' stateFIPS = "01", -#' countycode = "003", -#' sitenum = "0010" -#' ) -#' } -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object of quality assurance -#' performance evaluation data. for single monitoring site for the -#' sitenum, countycode and stateFIPS requested for the time frame -#' between bdate and edate. An AQS_Data_Mart_APIv2 is a 2 item named -#' list in which the first item ($Header) is a tibble of header -#' information from the AQS API and the second item ($Data) is a -#' tibble of the data returned. -#' @export -aqs_qa_annualperformanceeval_by_site <- function(parameter, bdate, edate, - stateFIPS, countycode, sitenum, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, sitenum, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - sitenum = sitenum, - cbdate = NA_Date_, - cedate = NA_Date_, - service = "qaAnnualPerformanceEvaluations" - ) - - qaape <- purrr::pmap(.l = params, .f = aqs_services_by_site) - if (!return_header) qaape %<>% aqs_removeheader - return(qaape) -} - - -#' @title aqs_qa_annualperformanceevaltransaction_by_site -#' @description \lifecycle{stable} -#' Returns AQS submissions transaction format (RD) of the annual -#' performance evaluation data (raw). Includes data pairs for -#' QA - aggregated by site for a parameter code aggregated by matching -#' input parameter, sitenum, countycode and stateFIPS provided for -#' bdate - edate time frame. -#' @note The AQS API only allows for a single year of quality assurance -#' Annual Performance Evaluations transaction data to be retrieved at a -#' time. This function conveniently extracts date information from the -#' bdate and edate parameters then makes repeated calls to the AQSAPI -#' retrieving a maximum of one calendar year of data at a time. Each -#' calendar year of data requires a separate API call so multiple years -#' of data will require multiple API calls. As the number of years of -#' data being requested increases so does the length of time that it -#' will take to retrieve results. There is also a 5 second wait time -#' inserted between successive API calls to prevent overloading the API -#' server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_site functions -#' @inheritParams aqs_services_by_site -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @importFrom magrittr `%<>%` -#' @examples #Returns a tibble containing annual performance evaluation data -#' # (raw) for ozone at the Fairhope site in Baldwin County, AL for -#' # 2017 in RD format. -#' \dontrun{aqs_qa_annualperformanceevaltransaction_by_site(parameter = "44201", -#' bdate = as.Date("20170101", -#' format = "%Y%m%d"), -#' edate = as.Date("20171231", -#' format = "%Y%m%d"), -#' stateFIPS = "01", -#' countycode = "003", -#' sitenum = "0010" -#' ) -#' } -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object of quality assurance -#' annual performance evaluation data in the RD format for a single -#' monitoring site for the sitenum, countycode and stateFIPS requested -#' for the time frame between bdate and edate in the AQS. An -#' AQS_Data_Mart_APIv2 is a 2 item named list in which the first item -#' ($Header) is a tibble of header information from the AQS API and -#' the second item ($Data) is a tibble of the data returned. -#' @export -aqs_qa_annualperformanceevaltransaction_by_site <- function(parameter, bdate, - edate, stateFIPS, - countycode, sitenum, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, sitenum, - cbdate, cedate, return_header - ) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - sitenum = sitenum, - cbdate = NA_Date_, - cedate = NA_Date_, - service = "transactionsQaAnnualPerformanceEvaluations" - ) - - tqaape <- purrr::pmap(.l = params, .f = aqs_services_by_site) - if (!return_header) tqaape %<>% aqs_removeheader - return(tqaape) -} - - -#' @title aqs_quarterlysummary_by_site -#' @description \lifecycle{stable} -#' Returns a tibble or an AQS_Data Mart_APIv2 S3 object of quarterly summary -#' data aggregated by site with the provided parameternum, stateFIPS, -#' county_code, and sitenum for bdate - edate time frame. -#' @note The AQS API only allows for a single year of quarterly summary to be -#' retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' -#' Also Note that for quarterly data, only the year portion of the bdate -#' and edate are used and all 4 quarters in the year are returned. -#' @family Aggregate _by_county functions -#' @inheritParams aqs_services_by_site -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object that contains quarterly -#' summary statistics for the given parameter for a single countycode -#' and stateFIPS combination. An AQS_Data Mart_APIv2 is a 2 item named -#' list in which the first item ($Header) is a tibble of header -#' information from the AQS API and the second item ($Data) is a -#' tibble of the data returned. -#' @examples # returns a tibble containing quarterly summaries for -#' # FRM/FEM PM2.5 data for Millbrook School in Wake County, NC -#' # for each quarter of 2016 -#' \dontrun{aqs_quarterlysummary_by_site(parameter = "88101", -#' bdate = as.Date("20160101", -#' format = "%Y%m%d"), -#' edate = as.Date("20160331", -#' format = "%Y%m%d"), -#' stateFIPS = "37", -#' countycode = "183", -#' sitenum = "0014" -#' ) -#' } -#' @export -aqs_quarterlysummary_by_site <- function(parameter, bdate, edate, stateFIPS, - countycode, sitenum, cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE) -{ - AQS_domain <- "aqs.epa.gov" - checkaqsparams(parameter, bdate, edate, stateFIPS, countycode, sitenum, - cbdate, cedate, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - countycode = countycode, - sitenum = sitenum, - service = "quarterlyData", - cbdate = cbdate, - cedate = cedate, - AQS_domain = AQS_domain - ) - - quarterlysummary <- purrr::pmap(.l = params, .f = aqs_services_by_site) - if (!return_header) quarterlysummary %<>% aqs_removeheader - return(quarterlysummary) -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/bystate.R b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/bystate.R deleted file mode 100644 index efba492..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/bystate.R +++ /dev/null @@ -1,908 +0,0 @@ -#' @section by_state aggregate functions - - -#' @title aqs_monitors_by_state -#' @description \lifecycle{stable} -#' Returns a table of monitors and related metadata at sites with the -#' provided parameter, and stateFIPS for bdate - edate time frame. -#' @note All monitors that operated between the bdate and edate will be returned -#' @family Aggregate_by_state functions -#' @inheritParams aqs_services_by_state -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two item -#' list that contains header information returned from -#' the API server mostly used for debugging purposes in -#' addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object of monitors from the -#' selected state -#' @examples # returns a tibble of SO2 monitors in Hawaii -#' # that were operating on May 01, 2017 -#' \dontrun{aqs_monitors_by_state(parameter="88101", -#' bdate=as.Date("20170101", -#' format="%Y%m%d"), -#' edate=as.Date("20171231", -#' format="%Y%m%d"), -#' stateFIPS="01" -#' ) -#' } -#' -#' @export -aqs_monitors_by_state <- function(parameter, bdate, edate, stateFIPS, - cbdate = NA_Date_, cedate = NA_Date_, - return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, cbdate, cedate, - return_header) - - # aqs_monitors_by_* functions don't call aqsmultiyearparams() since the - # monitors API call accepts multiple years of data on the server, purrr::pmap - # is used so that the output is consistent with other RAQSAPI functions. - params <- tibble(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - service = "monitors", - cbdate = cbdate, - cedate = cedate) %>% - dplyr::select_if(function(x) {!all(is.na(x))}) - - monitors <- purrr::pmap(.l = params, .f = aqs_services_by_state) - if (!return_header) monitors %<>% aqs_removeheader - return(monitors) -} - - -#' @title aqs_sampledata_by_state -#' @description \lifecycle{stable} -#' Returns sample data where the data is aggregated at the state -#' level. If return_header is FALSE (default) this function -#' returns a single dataframe with the requested data. If -#' return_header is TRUE returns a list of AQSAPI_v2 objects -#' where each index of the list is an individual RAQSAPI_v2 -#' object returned from each successive call to the AQS API. -#' RAQSAPI_v2 objects are two item list where the $Data portion -#' contains data that contains sample air monitoring data at a -#' site with the input parameter and stateFIPS provided for -#' bdate - edate time frame. The $Header is a tibble of header -#' information from the API call /(useful for debugging/). This -#' function returns NULL is bdate > edate. -#' @note The AQS API only allows for a single year of sampledata to be retrieved -#' at a time. This function conveniently extracts date information from -#' the bdate and edate parameters then makes repeated calls to the -#' AQSAPI retrieving a maximum of one calendar year of data at a time. -#' Each calendar year of data requires a separate API call so multiple -#' years of data will require multiple API calls. As the number of years -#' of data being requested increases so does the length of time that it -#' will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate_by_state functions -#' @inheritParams aqs_services_by_state -#' @importFrom magrittr `%<>%` -#' @importFrom purrr pmap -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two item -#' list that contains header information returned from -#' the API server mostly used for debugging purposes in -#' addition to the data requested. -#' @return a tibble or an AQS_Data_Mart_APIv2 S3 object containing sample data -#' for all monitors matching stateFIPS for the given parameter. -#' An AQS_Data Mart_APIv2 is a 2 item named list in which the first -#' item /(/$Header/) is a tibble of header information from the -#' AQS API and the second item /(/$Data/) is a tibble of the data -#' returned. -#' @examples # Returns a tibble with all benzene samples from -#' # North Carolina collected from May 15th, 1995 - May 15, 1999 -#' \dontrun{aqs_sampledata_by_state(parameter = "45201", -#' bdate = as.Date("19950515", -#' format="%Y%m%d" -#' ), -#' edate = as.Date("19990515", -#' format = "%Y%m%d"), -#' stateFIPS = "37" -#' ) -#' } -#' @export -aqs_sampledata_by_state <- function(parameter, bdate, edate, stateFIPS, - duration = NA_character_, - cbdate = NA_Date_, cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, duration, cbdate, - cedate, return_header) - -params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - duration = duration, - service = "sampleData", - cbdate = cbdate, - cedate = cedate - ) - - sampledata <- purrr::pmap(.l = params, .f = aqs_services_by_state) - if (!return_header) sampledata %<>% aqs_removeheader - return(sampledata) -} - - -#' @title aqs_annualsummary_by_state -#' @description \lifecycle{stable} -#' Returns multiple years of data where annual data is -#' aggregated at the state level. Returned is an annual summary -#' matching the input parameter and stateFIPS -#' provided for bdate - edate time frame. The data -#' returned is summarized at the annual level. Variables -#' returned include mean value, maxima, percentiles, and etc. If -#' return_header is FALSE (default) the object returned is a -#' tibble, if TRUE an AQS_API_v2 object. -#' @note The AQS API only allows for a single year of annualsummary to be -#' retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate_by_state functions -#' @inheritParams aqs_services_by_state -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object that containing annual -#' summary data for the stateFIPS requested. A AQS_Data Mart_APIv2 is -#' a 2 item named list in which the first item ($Header) is a tibble -#' of header information from the AQS API and the second item ($Data -#' is a tibble of the data returned. -#' @examples # returns a tibble of all benzene annualy -#' # summaries from North Carolina collected for 1995 -#' \dontrun{aqs_annualsummary_by_state(parameter = "45201", -#' bdate = as.Date("19950515", -#' format="%Y%m%d" -#' ), -#' edate = as.Date("19950515", -#' format = "%Y%m%d" -#' ), -#' stateFIPS = "37" -#' ) -#' } -#' @export -aqs_annualsummary_by_state <- function(parameter, bdate, edate, stateFIPS, - cbdate = NA_Date_, cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, cbdate, cedate, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - service = "annualData", - cbdate = cbdate, - cedate = cedate - ) - - annualsummary <- purrr::pmap(.l = params, .f = aqs_services_by_state) - if (!return_header) annualsummary %<>% aqs_removeheader - return(annualsummary) -} - - -#' @title aqs_qa_blanks_by_state -#' @description \lifecycle{stable} -#' Returns a table of blank quality assurance data . -#' Blanks are unexposed sample collection devices (e.g., -#' filters) that are transported with the exposed sample devices -#' to assess if contamination is occurring during the transport -#' or handling of the samples. Data is aggregated at the state level. -#' @note The AQS API only allows for a single year of qa_blank data to be -#' retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate_by_state functions -#' @inheritParams aqs_services_by_state -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data_Mart_APIv2 S3 object that contains quality -#' assurance blank sample data for all monitors within the input -#' stateFIPS. An AQS_Data_Mart_APIv2 is a 2 item named -#' list in which the first item ($Header) is a tibble of header -#' information from the AQS API and the second item ($Data) is a -#' tibble of the data returned. -#' @examples # returns a tibble which contains PM2.5 blank data -#' # for Alabama for January 2018 -#' \dontrun{aqs_qa_blanks_by_state(parameter = "88101", -#' bdate = as.Date("20180101", -#' format = "%Y%m%d" -#' ), -#' edate = as.Date("20180131", -#' format = "%Y%m%d"), -#' stateFIPS = "01" -#' ) -#' } -#' @export -aqs_qa_blanks_by_state <- function(parameter, bdate, edate, stateFIPS, - cbdate = NA_Date_, cedate = NA_Date_, - return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, cbdate, cedate, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - service = "qaBlanks", - cbdate = cbdate, - cedate = cedate - ) - - blanks <- purrr::pmap(.l = params, .f = aqs_services_by_state) - if (!return_header) blanks %<>% aqs_removeheader - return(blanks) -} - - -#' @title aqs_dailysummary_by_state -#' @description \lifecycle{stable} -#' Returns multiple years of data where daily data is -#' aggregated at the state level. Returned is a daily summary -#' matching the input parameter and stateFIPS provided for bdate - edate -#' time frame. Data is aggregated at the state level. Variables returned -#' include mean value, maxima, percentiles, and etc. -#' @note The AQS API only allows for a single year of dailysummary to be -#' retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate_by_state functions -#' @inheritParams aqs_services_by_state -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two item -#' list that contains header information returned from -#' the API server mostly used for debugging purposes in -#' addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object that contains daily -#' summary statistics for the given parameter for a single stateFIPS. -#' An AQS_Data Mart_APIv2 is a 2 item named list in which the first -#' item ($Header) is a tibble of header information from the AQS API -#' and the second item ($Data) is a tibble of the data returned. -#' @examples # returns a tibble of all benzene daily -#' # summaries from North Carolina collected on May 15th, 1995 -#' \dontrun{aqs_dailysummary_by_state(parameter = "45201", -#' bdate = as.Date("19950515", -#' format="%Y%m%d" -#' ), -#' edate = as.Date("19970515", -#' format = "%Y%m%d" -#' ), -#' stateFIPS = "37" -#' ) -#' } -#' @export -aqs_dailysummary_by_state <- function(parameter, bdate, edate, stateFIPS, - cbdate = NA_Date_, cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, cbdate, cedate, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - service = "dailyData", - cbdate = cbdate, - cedate = cedate - ) - - dailysummary <- purrr::pmap(.l = params, .f = aqs_services_by_state) - if (!return_header) dailysummary %<>% aqs_removeheader - return(dailysummary) -} - - -#' @title aqs_qa_collocated_assessments_by_state -#' @description \lifecycle{stable} -#' Returns a table of collocated assessment data aggregated by -#' matching input parameter and stateFIPS provided for bdate - -#' edate time frame. -#' @note The AQS API only allows for a single year of collocated assessments -#' data to be retrieved at a time. This function conveniently extracts -#' date information from the bdate and edate parameters then makes -#' repeated calls to the AQSAPI retrieving a maximum of one calendar -#' year of data at a time. Each calendar year of data requires a -#' separate API call so multiple years of data will require multiple API -#' calls. As the number of years of data being requested increases so -#' does the length of time that it will take to retrieve results. There -#' is also a 5 second wait time inserted between successive API calls to -#' prevent overloading the API server. This operation has a linear run -#' time of /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate_by_state functions -#' @inheritParams aqs_services_by_state -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -#' assurance collocated assessment data for monitors within a state. -#' An AQS_Data Mart_APIv2 is a 2 item named list in which the first -#' item ($Header) is a tibble of header information from the AQS API -#' and the second item ($Data) is a tibble of the data returned. -#' @examples # returns a tibble of collocated -#' # assessment data for FRM2.5 for January 2013 -#' \dontrun{aqs_qa_collocated_assessments_by_state(parameter="88101", -#' bdate = as.Date("20130101", -#' format = "%Y%m%d" -#' ), -#' edate = as.Date("20150131", -#' format = "%Y%m%d" -#' ), -#' stateFIPS = "01" -#' ) -#' } -#' @export -aqs_qa_collocated_assessments_by_state <- function(parameter, bdate, edate, - stateFIPS, cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, cbdate, cedate, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - service = "qaCollocatedAssessments", - cbdate = cbdate, - cedate = cedate - ) - - colocatedsummary <- purrr::pmap(.l = params, .f = aqs_services_by_state) - if (!return_header) colocatedsummary %<>% aqs_removeheader - return(colocatedsummary) -} - - -#' @title aqs_qa_flowrateverification_by_state -#' @description \lifecycle{stable} -#' Returns a table containing flow rate Verification data for a -#' parameter code aggregated matching input parameter, and -#' stateFIPS, provided for bdate - edate time frame. -#' @note The AQS API only allows for a single year of flow rate verifications to -#' be retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate_by_state functions -#' @inheritParams aqs_services_by_state -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -#' assurance flow rate verification data for monitors within a state. -#' An AQS_Data Mart_APIv2 is a 2 item named list in which the first -#' item ($Header) is a tibble of header information from the AQS API -#' and the second item ($Data) is a tibble of the data returned. -#' @examples # Returns a tibble of flow rate verification data for the state of -#' # Alabama for 2017-2019 -#' \dontrun{aqs_qa_flowrateverification_by_state(parameter = "88101", -#' bdate = as.Date("20170101", -#' format = "%Y%m%d" -#' ), -#' edate = as.Date("20190131", -#' format="%Y%m%d" -#' ), -#' stateFIPS = "01" -#' ) -#' } -#' @export -aqs_qa_flowrateverification_by_state <- function(parameter, bdate, edate, - stateFIPS, cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, cbdate, cedate, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - service = "qaFlowRateVerifications", - cbdate = cbdate, - cedate = cedate - ) - - frv <- purrr::pmap(.l = params, .f = aqs_services_by_state) - if (!return_header) frv %<>% aqs_removeheader - return(frv) -} - - -#' @title aqs_qa_flowrateaudit_by_state -#' @description \lifecycle{stable} -#' Returns a table containing flow rate audit -#' data aggregated by parameter code and stateFIPS for -#' bdate - edate time frame. -#' @note The AQS API only allows for a single year of flow rate audit data to -#' be retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate_by_state functions -#' @inheritParams aqs_services_by_state -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two item -#' list that contains header information returned from -#' the API server mostly used for debugging purposes in -#' addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing flow rate -#' audit data for the requested stateFIPS. An -#' AQS_Data_Mart_APIv2 object is a 2 item named list in which the -#' first item ($Header) is a tibble of header information from the -#' AQS API and the second item ($Data) is a tibble of the data -#' returned. -#' @examples # returns a tibble of flow rate audit -#' # data for Alabama in January 2018 -#' \dontrun{aqs_qa_flowrateaudit_by_state(parameter = "88101", -#' bdate = as.Date("20170101", -#' format = "%Y%m%d"), -#' edate = as.Date("20180131", -#' format = "%Y%m%d"), -#' stateFIPS = "01" -#' ) -#' } -#' @export -aqs_qa_flowrateaudit_by_state <- function(parameter, bdate, edate, stateFIPS, - cbdate = NA_Date_, cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, cbdate, cedate, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - service = "qaFlowRateAudits", - cbdate = cbdate, - cedate = cedate - ) - - fra <- purrr::pmap(.l = params, .f = aqs_services_by_state) - if (!return_header) fra %<>% aqs_removeheader - return(fra) -} - - -#' @title aqs_qa_one_point_qc_by_state -#' @description \lifecycle{stable} -#' Returns a tibble or an AQS_Data Mart_APIv2 S3 -#' object containing Quality assurance data - flow rate audit -#' raw data aggregated by state FIPS. -#' @note The AQS API only allows for a single year of one point qc data to -#' be retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate_by_state functions -#' @inheritParams aqs_services_by_state -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. If TRUE -#' returns a AQSAPI_v2 object which is a two item -#' list that contains header information returned from -#' the API server mostly used for debugging purposes in -#' addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing one point -#' qc data within a state. A AQS_Data_Mart_APIv2 object is a -#' 2 item named list in which the first item ($Header) is a tibble -#' of header information from the AQS API and the second item -#' ($Data) is a tibble of the data returned. -#' @examples # returns a tibble of one point QC check -#' # data for ozone in Massachusettes in January 2018 -#' \dontrun{aqs_qa_one_point_qc_by_state(parameter = "44201", -#' bdate = as.Date("20170101", -#' format = "%Y%m%d" -#' ), -#' edate = as.Date("20190131", -#' format = "%Y%m%d" -#' ), -#' stateFIPS = "25" -#' ) -#' } -#' @export -aqs_qa_one_point_qc_by_state <- function(parameter, bdate, edate, stateFIPS, - cbdate = NA_Date_, cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, cbdate, cedate, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - service = "qaOnePointQcRawData", - cbdate = cbdate, - cedate = cedate - ) - - opqcc <- purrr::pmap(.l = params, .f = aqs_services_by_state) - if (!return_header) opqcc %<>% aqs_removeheader - return(opqcc) -} - - -#' @title aqs_qa_pep_audit_by_state -#' @description \lifecycle{stable} -#' Returns a table of Performance Evaluation Program (PEP) audit -#' data aggregated by parameter code, and stateFIPS for the time -#' frame between bdate and edate. -#' @note The AQS API only allows for a single year of one point pep audit data -#' to be retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate_by_state functions -#' @inheritParams aqs_services_by_state -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. If TRUE -#' returns a AQSAPI_v2 object which is a two item -#' list that contains header information returned from -#' the API server mostly used for debugging purposes in -#' addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -#' assurance PEP audit data within a state. A AQS_Data_Mart_APIv2 -#' object is a 2 item named list in which the first item ($Header) is -#' a tibble of header information from the AQS API and the second item -#' ($Data) is a tibble of the data returned. -#' @examples # returns a tibble of PEP audit data for PM2.5 in Alabama 2017 -#' \dontrun{aqs_qa_pep_audit_by_state_multiyear(parameter="88101", -#' bdate=as.Date("20160101", -#' format="%Y%m%d"), -#' edate=as.Date("20171231", -#' format="%Y%m%d"), -#' stateFIPS="01" -#' ) -#' } -#' @export -aqs_qa_pep_audit_by_state <- function(parameter, bdate, edate, stateFIPS, - cbdate = NA_Date_, cedate = NA_Date_, - return_header = FALSE - ) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, cbdate, cedate, - return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - service = "qaPepAudits", - cbdate = cbdate, - cedate = cedate - ) - - pepaudit <- purrr::pmap(.l = params, .f = aqs_services_by_state) - if (!return_header) pepaudit %<>% aqs_removeheader - return(pepaudit) -} - - -#' @title aqs_transactionsample_by_state -#' @description \lifecycle{stable} -#' Returns transactionsample data - aggregated by state -#' in the AQS Submission Transaction Format (RD) sample (raw) data for -#' a parameter code aggregated by matching input parameter, and -#' stateFIPS provided for bdate - edate time frame. Includes data both -#' in submitted and standard units -#' @note The AQS API only allows for a single year of transaction data to be -#' retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of -#' data at a time. Each calendar year of data requires a separate API -#' call so multiple years of data will require multiple API calls. -#' As the number of years of data being requested increases so does the -#' length of time that it will take to retrieve results. There is also a -#' 5 second wait time inserted between successive API calls to prevent -#' overloading the API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_state functions -#' @inheritParams aqs_services_by_state -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @importFrom magrittr `%<>%` -#' @examples #Returns a AQS_Data Mart_APIv2 S3 object of -#' \dontrun{ # Returns a tibble containing benzene transaction sample -#' # data for North Carolina on May 15, 1995 -#' aqs_transactionsample_by_state(parameter = "45201", -#' bdate = as.Date("19950515", -#' format = "%Y%m%d"), -#' edate = as.Date("19950515", -#' format = "%Y%m%d"), -#' stateFIPS = "37" -#' ) -#' } -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object of transaction sample -#' (raw) data in the AQS submission transaction format (RD) -#' corresponding to the inputs provided. -#' @export -aqs_transactionsample_by_state <- function(parameter, bdate, edate, stateFIPS, - return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - service = "transactionsSample" - ) - - transactionsample <- purrr::pmap(.l = params, .f = aqs_services_by_state) - if (!return_header) transactionsample %<>% aqs_removeheader - return(transactionsample) -} - -#' @title aqs_qa_annualperformanceeval_by_state -#' @description \lifecycle{stable} -#' Returns quality assurance performance evaluation data - aggregated by -#' state for a parameter code aggregated by matching input -#' parameter, countycode and stateFIPS provided for -#' bdate - edate time frame. -#' @note The AQS API only allows for a single year of quality assurance -#' Annual Performance Evaluation data to be retrieved at a time. This -#' function conveniently extracts date information from the bdate -#' and edate parameters then makes repeated calls to the AQSAPI -#' retrieving a maximum of one calendar year of data at a time. Each -#' calendar year of data requires a separate API call so multiple years -#' of data will require multiple API calls. As the number of years of -#' data being requested increases so does the length of time that it -#' will take to retrieve results. There is also a 5 second wait time -#' inserted between successive API calls to prevent overloading the API -#' server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_state functions -#' @inheritParams aqs_services_by_state -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @importFrom magrittr `%<>%` -#' @examples # Returns a tibble containing annual performance evaluation -#' # data for ozone in Alabamba for 2017. -#' \dontrun{ aqs_qa_annualperformanceeval_by_state(parameter = "44201", -#' bdate = as.Date("20170101", -#' format = "%Y%m%d"), -#' edate = as.Date("20171231", -#' format = "%Y%m%d"), -#' stateFIPS = "01" -#' ) -#' } -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object of quality assurance -#' performance evaluation data. for single monitoring site for the -#' sitenum, countycode and stateFIPS requested for the time frame -#' between bdate and edate. An AQS_Data_Mart_APIv2 is a 2 item named -#' list in which the first item ($Header) is a tibble of header -#' information from the AQS API and the second item ($Data) is a -#' tibble of the data returned. -#' @export -aqs_qa_annualperformanceeval_by_state <- function(parameter, bdate, edate, - stateFIPS, - return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - service = "qaAnnualPerformanceEvaluations" - ) - - qaape <- purrr::pmap(.l = params, .f = aqs_services_by_state) - if (!return_header) qaape %<>% aqs_removeheader - return(qaape) -} - - -#' @title aqs_qa_annualperformanceevaltransaction_by_state -#' @description \lifecycle{stable} -#' Returns AQS submissions transaction format (RD) of the annual -#' performance evaluation data (raw). Includes data pairs for -#' QA - aggregated by state for a parameter code aggregated by -#' matching input parameter and stateFIPS provided for bdate - edate -#' time frame. -#' @note The AQS API only allows for a single year of quality assurance -#' Annual Performance Evaluations transaction data to be retrieved at a -#' time. This function conveniently extracts date information from the -#' bdate and edate parameters then makes repeated calls to the AQSAPI -#' retrieving a maximum of one calendar year of data at a time. Each -#' calendar year of data requires a separate API call so multiple years -#' of data will require multiple API calls. As the number of years of -#' data being requested increases so does the length of time that it -#' will take to retrieve results. There is also a 5 second wait time -#' inserted between successive API calls to prevent overloading the API -#' server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' @family Aggregate _by_state functions -#' @inheritParams aqs_services_by_state -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @importFrom magrittr `%<>%` -#' @examples # Returns a tibble containing annual performance evaluation data -#' # for ozone in Alabmba for 2017 in RD format. -#' \dontrun{ -#' aqs_qa_annualperformanceevaltransaction_by_state(parameter = "44201", -#' bdate = as.Date("20170101", -#' format = "%Y%m%d"), -#' edate = as.Date("20171231", -#' format = "%Y%m%d") -#' stateFIPS = "01" -#' ) -#' } -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object of quality assurance -#' performance evaluation data. for single monitoring site for the -#' sitenum, countycode and stateFIPS requested for the time frame -#' between bdate and edate. An AQS_Data_Mart_APIv2 is a 2 item named -#' list in which the first item ($Header) is a tibble of header -#' information from the AQS API and the second item ($Data) is a -#' tibble of the data returned. -#' @export -aqs_qa_annualperformanceevaltransaction_by_state <- function(parameter, bdate, - edate, stateFIPS, - return_header = FALSE) -{ - checkaqsparams(parameter, bdate, edate, stateFIPS, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - service = "qaAnnualPerformanceEvaluations" - ) - - tqaape <- purrr::pmap(.l = params, .f = aqs_services_by_state) - if (!return_header) tqaape %<>% aqs_removeheader - return(tqaape) -} - - -#' @title aqs_quarterlysummary_by_state -#' @description \lifecycle{stable} -#' Returns a tibble or an AQS_Data Mart_APIv2 S3 -#' object of quarterly summary data aggregated by stateFIPS. -#' @note The AQS API only allows for a single year of quarterly summary to be -#' retrieved at a time. This function conveniently extracts date -#' information from the bdate and edate parameters then makes repeated -#' calls to the AQSAPI retrieving a maximum of one calendar year of data -#' at a time. Each calendar year of data requires a separate API call so -#' multiple years of data will require multiple API calls. As the number -#' of years of data being requested increases so does the length of time -#' that it will take to retrieve results. There is also a 5 second wait -#' time inserted between successive API calls to prevent overloading the -#' API server. This operation has a linear run time of -#' /(Big O notation: O/(n + 5 seconds/)/). -#' -#' Also Note that for quarterly data, only the year portion of the bdate -#' and edate are used and all 4 quarters in the year are returned. -#' @family Aggregate _by_state functions -#' @inheritParams aqs_services_by_state -#' @importFrom magrittr `%<>%` -#' @param return_header If FALSE (default) only returns data requested. -#' If TRUE returns a AQSAPI_v2 object which is a two -#' item list that contains header information returned -#' from the API server mostly used for debugging -#' purposes in addition to the data requested. -#' @return a tibble or an AQS_Data Mart_APIv2 S3 object that contains quarterly -#' summary statistics for the given parameter for a stateFIPS. -#' An AQS_Data Mart_APIv2 is a 2 item named list in which the first -#' item ($Header) is a tibble of header information from the AQS API -#' and the second item ($Data) is a tibble of the data returned. -#' @examples # Returns an aqs S3 object containing quarterly summaries for -#' # FRM/FEM PM2.5 data for North Carolina for each quater of 2016 -#' \dontrun{aqs_quarterlysummary_by_state(parameter = "88101", -#' bdate = as.Date("20160101", -#' format = "%Y%m%d"), -#' edate = as.Date("20171231", -#' format = "%Y%m%d"), -#' stateFIPS = "37" -#' ) -#' } -#' @export -aqs_quarterlysummary_by_state <- function(parameter, bdate, edate, stateFIPS, - cbdate = NA_Date_, cedate = NA_Date_, - return_header = FALSE) -{ - AQS_domain <- "aqs.epa.gov" - checkaqsparams(parameter, bdate, edate, stateFIPS, - cbdate, cedate, return_header) - - params <- aqsmultiyearparams(parameter = parameter, - bdate = bdate, - edate = edate, - stateFIPS = stateFIPS, - service = "quarterlyData", - cbdate = cbdate, - cedate = cedate, - AQS_domain = AQS_domain - ) - - quarterlysummary <- purrr::pmap(.l = params, .f = aqs_services_by_state) - if (!return_header) quarterlysummary %<>% aqs_removeheader - return(quarterlysummary) -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/deprecated.R b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/deprecated.R deleted file mode 100644 index c63307e..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/deprecated.R +++ /dev/null @@ -1,183 +0,0 @@ -#' @title aqs_qa_annualpeferomanceeval_by_site -#' @description \lifecycle{deprecated} -#' aqs_qa_annualpeferomanceeval_by* functions have been renamed to -#' aqs_qa_annualperformance* functions, please use these -#' functions instead. -#' -#' @family deprecated RAQSAPI functions -#' @importFrom rlang abort -#' @export -#' @rdname deprecated.Rd -aqs_qa_annualpeferomanceeval_by_site <- function() -{ - abort(message = "aqs_qa_annualpeferomanceeval_by* functions have been renamed - to aqs_qa_annualperformance* functions, please use these - functions instead." - ) -} - - -#' @title aqs_qa_annualpeferomanceeval_by_county -#' @description \lifecycle{deprecated} -#' aqs_qa_annualpeferomanceeval_by* functions have been renamed to -#' aqs_qa_annualperformance* functions, please use these -#' functions instead. -#' -#' @family deprecated RAQSAPI functions -#' @importFrom rlang abort -#' @export -#' @rdname deprecated.Rd -aqs_qa_annualpeferomanceeval_by_county <- function() -{ - abort(message = "aqs_qa_annualpeferomanceeval_by* functions have been renamed - to aqs_qa_annualperformance* functions, please use these - functions instead." - ) -} - -#' @title aqs_qa_annualpeferomanceeval_by_state -#' @description \lifecycle{deprecated} -#' aqs_qa_annualpeferomanceeval_by* functions have been renamed to -#' aqs_qa_annualperformance* functions, please use these functions -#' instead. -#' -#' @family deprecated RAQSAPI functions -#' @importFrom rlang abort -#' @export -#' @rdname deprecated.Rd -aqs_qa_annualpeferomanceeval_by_state <- function() -{ - abort(message = "aqs_qa_annualpeferomanceeval_by* functions have been renamed - to aqs_qa_annualperformance_by* functions, please use these - functions instead." - ) -} - -#' @title aqs_qa_annualpeferomanceeval_by_pqao -#' @description \lifecycle{deprecated} -#' aqs_qa_annualpeferomanceeval_by* functions have been renamed to -#' aqs_qa_annualperformance_by* functions, please use these -#' functions instead. -#' -#' @family deprecated RAQSAPI functions -#' @importFrom rlang abort -#' @export -#' @rdname deprecated.Rd -aqs_qa_annualpeferomanceeval_by_pqao <- function() -{ - abort(message = "aqs_qa_annualpeferomanceeval_by* functions have been renamed - to aqs_qa_annualperformance_by* functions, please use these - functions instead." - ) -} - - -#' @title aqs_qa_annualpeferomanceeval_by_MA -#' @description \lifecycle{deprecated} -#' aqs_qa_annualpeferomanceeval_by* functions have been renamed -#' to -#' aqs_qa_annualperformance_by* functions, please use these -#' functions instead. -#' -#' @family deprecated RAQSAPI functions -#' @importFrom rlang abort -#' @export -#' @rdname deprecated.Rd -aqs_qa_annualpeferomanceeval_by_MA <- function() -{ - abort(message = "aqs_qa_annualpeferomanceeval_by* functions have been - renamed to aqs_qa_annualperformance* functions, please use - these functions instead." - ) -} - -#' @title aqs_qa_annualpeferomanceevaltransaction_by_site -#' @description \lifecycle{deprecated} -#' aqs_qa_annualpeferomanceeval_by* functions have been renamed to -#' aqs_qa_annualperformance_by* functions, please use these -#' functions instead. -#' -#' @family deprecated RAQSAPI functions -#' @importFrom rlang abort -#' @export -#' @rdname deprecated.Rd -aqs_qa_annualpeferomanceevaltransaction_by_site <- function() -{ - abort(message = "aqs_qa_annualpeferomanceevaltransaction_by* functions have - been renamed to aqs_qa_annualperformancetransaction_by* - functions, please use these functions instead.") -} - - -#' @title aqs_qa_annualpeferomanceevaltransaction_by_county -#' @description \lifecycle{deprecated} -#' aqs_qa_annualpeferomanceeval_by* functions have been renamed to -#' aqs_qa_annualperformance_by* functions, please use these -#' functions instead. -#' -#' @family deprecated RAQSAPI functions -#' @importFrom rlang abort -#' @export -#' @rdname deprecated.Rd -aqs_qa_annualpeferomanceevaltransaction_by_county <- function() -{ - abort(message = "aqs_qa_annualpeferomanceevaltransaction_by* functions have - been renamed to aqs_qa_annualperformancetransaction_by* - functions, please use these functions instead.") -} - - -#' @title aqs_qa_annualpeferomanceevaltransaction_by_pqao -#' @description \lifecycle{deprecated} -#' aqs_qa_annualpeferomanceeval_by* functions have been renamed to -#' aqs_qa_annualperformance_by* functions, please use these -#' functions instead. -#' -#' @family deprecated RAQSAPI functions -#' @importFrom rlang abort -#' @export -#' @rdname deprecated.Rd -aqs_qa_annualpeferomanceevaltransaction_by_pqao <- function() -{ - abort(message = "aqs_qa_annualpeferomanceevaltransaction_by* functions have - been renamed to aqs_qa_annualperformancetransaction_by* - functions, please use these functions instead.") -} - -#' @title aqs_qa_annualpeferomanceevaltransaction_by_MA -#' @description \lifecycle{deprecated} -#' aqs_qa_annualpeferomanceeval_by* functions have been renamed to -#' aqs_qa_annualperformance_by* functions, please use these -#' functions instead. -#' -#' @family deprecated RAQSAPI functions -#' @importFrom rlang abort -#' @export -#' @rdname deprecated.Rd -aqs_qa_annualpeferomanceevaltransaction_by_MA <- function() -{ - abort(message = "aqs_qa_annualpeferomanceevaltransaction_by* functions have - been renamed to aqs_qa_annualperformancetransaction_by* - functions, please use these functions instead.") -} - - -#' @title aqs_ratelimit -#' @description \lifecycle{depricated} -#' @description a helper function that should not be called externally, used -#' as a primitive rate limit function for aqs. -#' @param waittime the number of seconds, encoded as a numeric, that the API -#' should wait after performing a API query -#' (defaults to 5 seconds, as recommended by the AQS team). -#' @note Although this function is designed to prevent users from exceeding -#' allowed data limits, it can not garuntee that the user exceed rate -#' limits. Users are advised to monitor their own usage to ensure that -#' data limits are not exceeded. Use of this package is at the users own -#' risk. The maintainers of this code assume no responsibility due to -#' anything that may happen as a result of using this code. -#' @return NULL -#' @noRd -aqs_ratelimit <- function(waittime=5L) -{ - Sys.sleep(waittime) -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/setupfunctions.R b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/setupfunctions.R deleted file mode 100644 index a005229..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/setupfunctions.R +++ /dev/null @@ -1,93 +0,0 @@ -#' @section RAQSAPI setup functions - - -#' @title aqs_credentials -#' @description \lifecycle{stable} -#' Sets the user credentials for the AQS API. This function -#' needs to be called once and only once every time this library -#' is re-loaded. Users must have a valid username and key which -#' can be obtained through the use of the aqs_sign_up function, -#' @seealso [aqs_sign_up()] to sign up for AQS data mart -#' credentials. -#' @importFrom rlang is_character -#' @param username a R character object which represents the email account that -#' will be used to connect to the AQS API. -#' @param key the key used in conjunction with the username given to connect to -#' AQS Data Mart. -#' @return None -#' @examples -#' #to authenticate an existing user the email address -#' # "John.Doe@myemail.com" and key = "MyKey" -#' # after calling this function please follow the instructions that are sent -#' # in the verification e-mail before proceeding. -#' \dontrun{aqs_credentials(username = "John.Doe@myemail.com", -#' key = "MyKey") -#' } -#' @export -aqs_credentials <- function(username = NA_character_, key = NA_character_) -{ - # nocov - #The code simply stores the credentials as a R option. Since the - #Data Mart server only issues a "key" and not a "password" we don't need to - #worry about securing the credentials with complicated code such as involving - #salt and hashes and etc. - if (!is.na(username) || - !is.na(key) || - !is_character(username) || - !is_character(key) - ) - { - options(aqs_username = username) - options(aqs_key = key) - #credentials <- options(list(aqs_username = username, aqs_key = key)) - #on.exit(options(credentials), add = TRUE) - } else {warning("Please enter a valid username and key \n") } -} #no cov end - - -#' @title aqs_sign_up -#' @description \lifecycle{stable} -#' Use this service to register as a new user or to reset an -#' existing user's key. A verification email will be sent to the -#' email account specified. To reset a password: If the request is -#' made with an email that is already registered, a new key will -#' be issued for that account and emailed to the listed address. -#' Usage is the same in either case. Refer to the email -#' message for further instructions before continuing. -#' @param email a R character object which represents the email account that -#' will be used to register with the AQS API or change an -#' existing user's key. A verification email will be sent to -#' the account specified. Follow the instructions -#' in the verification e-mail before proceeding to use any other -#' functionality of the AQS API. Register your credential -#' with the @3 [aqs_credentials()] before using the -#' other functions in this library. -#' @note The '@' character needs to be escaped with the '/' character. -#' @importFrom glue glue -#' @importFrom magrittr `%>%` -#' @importFrom httr2 request -#' @importFrom glue glue -#' @examples # to register a new user or generate a new key with the email -#' # address "John.Doe/@myemail.com" -#' \dontrun{aqs_sign_up(email = "John.Doe/@myemail.com")} -#' # after calling this function please follow the instructions that -#' # are sent in the verification e-mail before proceeding. -#' @return None -#' @export -aqs_sign_up <- function(email) -{ #nocov start - #We do not want aqs_sign_up registering new users as part of - #the unit testing proceedures. - - user_agent <- glue("User:{email} via RAQSAPI-{packageVersion('RAQSAPI')} - library for R") - - url <- glue("https://aqs.epa.gov/data/api/signup?email={email}") %>% - request() %>% - req_perform() - #for some reason user_agent isn't working - #%>% - #req_user_agent(string = user_agent) - glue("A verification email will be sent to {email} \n") %>% - message() -} #nocov end diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/zzz.R b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/zzz.R deleted file mode 100644 index 63078d3..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/R/zzz.R +++ /dev/null @@ -1,33 +0,0 @@ -#nocov start -.onLoad <- function(libname, pkgname) - { - utils::globalVariables(names = c("env.RAQSAPI", "AQSObject", "datetime"), - package = "RAQSAPI") - env.RAQSAPI <- Sys.getenv() - Sys.setenv("_R_CHECK_LENGTH_1_CONDITION_" = "TRUE") - invisible() -} - -.onUnLoad <- function(libname, pkgname) -{ - Sys.setenv(env.RAQSAPI) - invisible() -} - -#' @title .onAttach -#' @description prints out a friendly reminder message to the user when -#' the RAQSAPI library is loaded. -#' @inheritParams base .onAttech -#' @return NULL -#' @noRd -.onAttach <- function(libname, pkgname) - { - RAQSAPIstartupmessage <- paste("Use the function", - "RAQSAPI::aqs_credentials(username, key)", - "before using other RAQSAPI functions", - "See ?RAQSAPI::aqs_credentials for more information", - sep = "\n" - ) - packageStartupMessage(RAQSAPIstartupmessage) - } -#nocov end diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/build/stage23.rdb b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/build/stage23.rdb deleted file mode 100644 index 0be6e42..0000000 Binary files a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/build/stage23.rdb and /dev/null differ diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/build/vignette.rds b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/build/vignette.rds deleted file mode 100644 index 5ae86e0..0000000 Binary files a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/build/vignette.rds and /dev/null differ diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/CITATION b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/CITATION deleted file mode 100644 index c149f77..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/CITATION +++ /dev/null @@ -1,40 +0,0 @@ -bibentry(bibtype = "Manual", - title = "A R Interface to the US EPA Air Quality System - Data Mart API", - author = c(person(given = "Clinton", family = "Mccrowey", - email = "mccrowey.clinton@epa.gov", - role = c("cre", "aut"), - comment = "United States Enviornmental - Protection Agency Region 3 Air and - Radiation Division"), - person(given = "Timothy", family = "Sharac", - role = c("ctb","rev"), email = NULL, - comment = "United States Enviornmental - Protection Agency"), - person(given = "Nick", family = "Mangus", - email = NULL, role = c("rev"), - comment="United States Enviornmental - Protection Agency"), - person(given = "Doug", family = "Jager", - email = NULL, role = c("ctb", "rev"), - comment = "United States Enviornmental - Protection Agency"), - person(given = "Ryan",family = "Brown", - email = NULL, role = c("ctb", "rev"), - comment = "United States Enviornmental - Protection Agency"), - person(given = "Daniel", family = "Garver", - email = NULL, role = c("ctb", "rev"), - comment = "United States Enviornmental - Protection Agency"), - person(given = "Benjamin", family = "Wells", - email = NULL, role = c("ctb", "rev"), - comment="United States Enviornmental - Protection Agency"), - person(given = "Hayley", family = "Brittingham", - email = NULL, role = c("crr", "ctr"), - comment = "Neptune and Company") - ), - year = "2023", - url = "https://cran.r-project.org/package=RAQSAPI" - ) diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/WORDLIST b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/WORDLIST deleted file mode 100644 index 4f7ffe8..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/WORDLIST +++ /dev/null @@ -1,126 +0,0 @@ -APIv -AQS -AQSAPI -AQSDatamart -AQSobject -Acknowledgements -AirNow -Angly -annualpeferomanceeval -annualperformance -Badgecreatr -CBSA -CFR -CMD -Csárdi -DATAMART -Datamart -Github -Hogervorst -JSON -Lintr -Müller -ODBC -Organisation -PQAO -RAQSAPI's -RAQSAPIvignette -RAQSAPI’s -README -RESTful -RShowDoc -Rblogger's -Rblogger’s -Readme -Rmd -Tenenbaum -Tibble -USEPA -Usethis -Verifications -WORDLIST -Wickham -yellowgreen -Yu -annualdata -annualdataby -annualsummary -api -aqs -aqsweb -bdate -cbdate -cbsa -cbsas -cedate -changedate -codecov -countycode -cran -dailydataby -dailysummary -dailysummaryby -datamartAPI -devtools -durations -edate -epa -fieldsbyservice -flowrate -flowrateaudit -flowrateverification -github -gitignore -gtools -hexSticker -hexsticker -https -img -io -io’ -isavailable -keyring -keyrings -knownissues -lifecycle -maxlat -maxlon -md -metaData -metacran -minlat -minlon -ORCID -parameternum -pqao -pqaos -qa -qc -quarterlydata -quarterlysummary -rdname -removeheader -revisionhistory -rlang -sampledata -sampledataby -sampledurations -seealso -signup -sitenum -stateFIPS -submittal -svg -testthat -tibble -transactiondata -transactionsample -verifications -’Codecov -’GitHub’ -’Linter’ -’Repostatus’ -’Travis’ -importFrom -annualperformanceeval -annualperformanceevaltransaction diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/codecov.yml b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/codecov.yml deleted file mode 100644 index 04c5585..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/codecov.yml +++ /dev/null @@ -1,14 +0,0 @@ -comment: false - -coverage: - status: - project: - default: - target: auto - threshold: 1% - informational: true - patch: - default: - target: auto - threshold: 1% - informational: true diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/schemaorg.json b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/schemaorg.json deleted file mode 100644 index ddd5589..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/inst/schemaorg.json +++ /dev/null @@ -1,74 +0,0 @@ -{ - "@context": "https://schema.org", - "@graph": [ - { - "type": "SoftwareSourceCode", - "author": { - "type": "Person", - "email": "mccrowey.clinton@epa.gov", - "familyName": "Mccrowey", - "givenName": "Clinton" - }, - "codeRepository": "https://github.com/USEPA/RAQSAPI", - "contributor": [ - { - "type": "Person", - "familyName": "Sharac", - "givenName": "Timothy" - }, - { - "type": "Person", - "familyName": "Jager", - "givenName": "Doug" - }, - { - "type": "Person", - "familyName": "Brown", - "givenName": "Ryan" - }, - { - "type": "Person", - "familyName": "Garver", - "givenName": "Daniel" - }, - { - "type": "Person", - "familyName": "Wells", - "givenName": "Benjamin" - }, - { - "type": "Person", - "email": "edward.s.andrews@wv.gov", - "familyName": "Andrews", - "givenName": "Edward" - } - ], - "description": "Retrieve air monitoring data and associated metadata from the US Environmental Protection Agency's Air Quality System service using functions. See for details about the US EPA Data Mart API.", - "license": "https://spdx.org/licenses/MIT", - "name": "RAQSAPI: A Simple Interface to the US EPA Air Quality System Data Mart API", - "programmingLanguage": { - "type": "ComputerLanguage", - "name": "R", - "url": "https://r-project.org" - }, - "provider": { - "id": "https://cran.r-project.org", - "type": "Organization", - "name": "Comprehensive R Archive Network (CRAN)", - "url": "https://cran.r-project.org" - }, - "runtimePlatform": "R version 4.3.0 (2023-04-21 ucrt)", - "version": "2.0.5" - }, - { - "type": "SoftwareSourceCode", - "author": { - "type": "Person", - "email": "mccrowey.clinton@epa.gov", - "familyName": "Mccrowey", - "givenName": "Clinton" - }, - "name": "A R Interface to the US EPA Air Quality System\n Data Mart API" - } - ] -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/RAQSAPI.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/RAQSAPI.Rd deleted file mode 100644 index 033a43a..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/RAQSAPI.Rd +++ /dev/null @@ -1,63 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/RAQSAPI-package.R -\docType{package} -\name{RAQSAPI} -\alias{RAQSAPI} -\alias{RAQSAPI-package} -\title{RAQSAPI: A R Interface to The United States Environmental Protection -Agency's Air Quality System Data Mart RESTful API server.} -\description{ -RAQSAPI is a package for R that connects the R programming -environment to the United State's Environmental protection agency's -Air Quality System (AQS) Data Mart API for retrieval of air -monitoring data. - -There are two things that you must do before using this package. -\enumerate{ -\item If you have not done so yet register your username with Data Mart -\item Every time this library is reloaded AQS_API_credentials() function -must be called before continuing. -} - -please use vignette(RAQSAPI) for more details about this package. - -EPA Disclaimer: -This software/application was developed by the U.S. Environmental Protection -Agency (USEPA). No warranty expressed or implied is made regarding the -accuracy or utility of the system, nor shall the act of distribution -constitute any such warranty. The USEPA has relinquished control of the -information and no longer has responsibility to protect the integrity, -confidentiality or availability of the information. Any reference to specific -commercial products, processes, or services by service mark, trademark, -manufacturer, or otherwise, does not constitute or imply their endorsement, -recommendation or favoring by the USEPA. The USEPA seal and logo shall not -be used in any manner to imply endorsement of any commercial product or -activity by the USEPA or the United States Government. -} -\seealso{ -Useful links: -\itemize{ - \item \url{} - \item \url{} - \item Report bugs at \url{https://github.com/USEPA/RAQSAPI/issues} -} - -} -\author{ -\strong{Maintainer}: Clinton Mccrowey \email{mccrowey.clinton@epa.gov} (United States Environmental Protection Agency Region 3 Air and Radiation Division) - -Other contributors: -\itemize{ - \item Timothy Sharac (United States Environmental Protection Agency) [contributor, reviewer] - \item Nick Mangus (United States Environmental Protection Agency) [reviewer] - \item Doug Jager (United States Environmental Protection Agency) [contributor, reviewer] - \item Ryan Brown (United States Environmental Protection Agency) [contributor, reviewer] - \item Daniel Garver (United States Environmental Protection Agency) [contributor, reviewer] - \item Benjamin Wells (United States Environmental Protection Agency) [contributor, reviewer] - \item Hayley Brittingham (Neptune and Company) [corrector, contractor] - \item Jeffrey Hollister \email{hollister.jeff@epa.gov} (\href{https://orcid.org/0000-0002-9254-9740}{ORCID}) (United States Environmental Protection Agency) [reviewer] - \item Edward Andrews \email{edward.s.andrews@wv.gov} (West Virginia Department of Environmental Protection, Division of Air Quality) [reviewer, contributor] -} - -} -\keyword{internal} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_annualsummary_by_box.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_annualsummary_by_box.Rd deleted file mode 100644 index 7a0d5bb..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_annualsummary_by_box.Rd +++ /dev/null @@ -1,121 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bybox.R -\name{aqs_annualsummary_by_box} -\alias{aqs_annualsummary_by_box} -\title{aqs_annualsummary_by_box} -\usage{ -aqs_annualsummary_by_box( - parameter, - bdate, - edate, - minlat, - maxlat, - minlon, - maxlon, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{minlat}{a R character object which represents the minimum latitude of -a geographic box. Decimal latitude with north begin -positive. Only data north of this latitude will be -returned.} - -\item{maxlat}{a R character object which represents the maximum latitude of -a geographic box. Decimal latitude with north begin -positive. Only data south of this latitude will be -returned.} - -\item{minlon}{a R character object which represents the minimum longitude -of a geographic box. Decimal longitude with east begin -positive. Only data east of this longitude will be -returned.} - -\item{maxlon}{a R character object which represents the maximum longitude -of a geographic box. Decimal longitude with east begin -positive. Only data west of this longitude will be -returned. Note that -80 is less than -70.} - -\item{cbdate}{a R date object which represents a "beginning date of last -change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. If TRUE -returns a AQSAPI_v2 object which is a two item list that contains header -information returned from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object that containing annual -summary data for the box (area) requested. A AQS_Data Mart_APIv2 -is a 2 item named list in which the first item ($Header) is a -tibble of header information from the AQS API and the second item -($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns multiple years of data where annual data is -aggregated at the bounding box level. Returned is an annual -summary within the input parameter, latitude/longitude -bounding box provided for bdate - edate time frame. Variables -returned include mean value, maxima, percentiles, and etc. If -return_header is FALSE (default) the object returned is a -tibble, if TRUE an AQS_API_v2 object. -} -\note{ -The AQS API only allows for a single year of annualsummary to be -retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# Returns a tibble containing ozone annual summaries - # in the vicinity of central Alabama for the first two days - # of May, 2015 - \dontrun{aqs_annualsummary_by_box(parameter = "44201", - bdate = as.Date("20150501", - format = "\%Y\%m\%d"), - edate = as.Date("20170502", - format = "\%Y\%m\%d"), - minlat = "33.3", - maxlat = "33.6", - minlon = "-87.0", - maxlon = "-86.7" - ) - } -} -\seealso{ -Other Aggregate _by_box functions: -\code{\link{aqs_monitors_by_box}()}, -\code{\link{aqs_sampledata_by_box}()} -} -\concept{Aggregate _by_box functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_annualsummary_by_cbsa.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_annualsummary_by_cbsa.Rd deleted file mode 100644 index 7a512eb..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_annualsummary_by_cbsa.Rd +++ /dev/null @@ -1,103 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bycbsa.R -\name{aqs_annualsummary_by_cbsa} -\alias{aqs_annualsummary_by_cbsa} -\title{aqs_annualsummary_by_cbsa} -\usage{ -aqs_annualsummary_by_cbsa( - parameter, - bdate, - edate, - cbsa_code, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{cbsa_code}{a R character object which represents the 5 digit AQS Core -Based Statistical Area code (the same as the census code, -with leading zeros)} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. If TRUE -returns a AQSAPI_v2 object which is a two item list that contains header -information returned from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object that containing annual -summary data for the cbsa_code requested. A AQS_Data Mart_APIv2 is -a 2 item named list in which the first item ($Header) is a tibble -of header information from the AQS API and the second item ($Data) -is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns multiple years of data where annual data is -aggregated at the Core Based Statistical Area (CBSA) level. -Returned is an annual summary -matching the input parameter, and cbsa_code -provided for bdate - edate time frame. Variables returned -include mean value, maxima, percentiles, and etc. If -return_header is FALSE (default) the object returned is a -tibble, if TRUE an AQS_API_v2 object. -} -\note{ -The AQS API only allows for a single year of annualsummary to be -retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# Returns a tibble of annual summary $NO_{2}$ - # data the for Charlotte-Concord-Gastonia, NC cbsa on - # Janurary 01, 2017 - \dontrun{aqs_annualsummary_by_cbsa(parameter = "42602", - bdate = as.Date("20170101", - format = "\%Y\%m\%d" - ), - edate = as.Date("20170101", - format = "\%Y\%m\%d" - ), - cbsa_code = "16740" - ) - } -} -\seealso{ -Other Aggregate _by_cbsa functions: -\code{\link{aqs_dailysummary_by_cbsa}()}, -\code{\link{aqs_monitors_by_cbsa}()}, -\code{\link{aqs_sampledata_by_cbsa}()} -} -\concept{Aggregate _by_cbsa functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_annualsummary_by_county.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_annualsummary_by_county.Rd deleted file mode 100644 index 9c0c164..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_annualsummary_by_county.Rd +++ /dev/null @@ -1,120 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bycounty.R -\name{aqs_annualsummary_by_county} -\alias{aqs_annualsummary_by_county} -\title{aqs_annualsummary_by_county} -\usage{ -aqs_annualsummary_by_county( - parameter, - bdate, - edate, - stateFIPS, - countycode, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be -returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. If -TRUE returns a AQSAPI_v2 object which is a two item -list that contains header information returned from -the API server mostly used for debugging purposes in -addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object that containing annual -summary data for the countycode and stateFIPS requested. -A AQS_Data Mart_APIv2 is a 2 item named list in which the first -item ($Header) is a tibble of header information from the AQS API -and the second item ($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns multiple years of data where annual data is -aggregated at the county level. Returned is an annual summary -matching the input parameter, stateFIPS, and county_code -provided for bdate - edate time frame. Variables -returned include mean value, maxima, percentiles, and etc. If -return_header is FALSE (default) the object returned is a -tibble, if TRUE an AQS_API_v2 object. -} -\note{ -The AQS API only allows for a single year of annualsummary to be -retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# returns an aqs S3 object with annual summary FRM/FEM - # PM2.5 data for Wake County, NC between January - # and February 2016 - \dontrun{aqs_annualsummary_by_county(parameter = "88101", - bdate = as.Date("20160101", - format = "\%Y\%m\%d"), - edate = as.Date("20180228", - format = "\%Y\%m\%d"), - stateFIPS = "37", - countycode = "183" - ) - } -} -\seealso{ -Other Aggregate _by_county functions: -\code{\link{aqs_dailysummary_by_county}()}, -\code{\link{aqs_monitors_by_county}()}, -\code{\link{aqs_qa_annualperformanceeval_by_county}()}, -\code{\link{aqs_qa_blanks_by_county}()}, -\code{\link{aqs_qa_collocated_assessments_by_county}()}, -\code{\link{aqs_qa_flowrateaudit_by_county}()}, -\code{\link{aqs_qa_flowrateverification_by_county}()}, -\code{\link{aqs_qa_one_point_qc_by_county}()}, -\code{\link{aqs_qa_pep_audit_by_county}()}, -\code{\link{aqs_quarterlysummary_by_county}()}, -\code{\link{aqs_quarterlysummary_by_site}()}, -\code{\link{aqs_sampledata_by_county}()}, -\code{\link{aqs_transactionsample_by_county}()} -} -\concept{Aggregate _by_county functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_annualsummary_by_site.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_annualsummary_by_site.Rd deleted file mode 100644 index f299b08..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_annualsummary_by_site.Rd +++ /dev/null @@ -1,132 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bysite.R -\name{aqs_annualsummary_by_site} -\alias{aqs_annualsummary_by_site} -\title{aqs_annualsummary_by_site} -\usage{ -aqs_annualsummary_by_site( - parameter, - bdate, - edate, - stateFIPS, - countycode, - sitenum, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{sitenum}{a R character object which represents the 4 digit site number -(with leading zeros) within the county and state being -requested.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested as a -single tibble. If TRUE returns a list of AQSAPI_v2 -objects which is a two item list that contains header -information returned from the API server mostly used -for debugging purposes in addition to the data -requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing annual -summary data for the sitenum, countycode and stateFIPS requested. -A AQS_Data Mart_APIv2 is a 2 item named list in which the first -item ($Header) is a tibble of header information from the AQS API -and the second item ($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns multiple years of data where annual data is -aggregated at the site level. Returned is an annual summary -matching the input parameter, stateFIPS, county_code, and -sitenum provided for bdate - edate time frame. The data -returned is summarized at the annual level. Variables -returned include mean value, maxima, percentiles, and etc. If -return_header is FALSE (default) the object returned is a -tibble, if TRUE an AQS_API_v2 object. -} -\note{ -The AQS API only allows for a single year of annualsummary to be -retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# Returns a tibble of annual summary ozone - # data for the Millbrook School site (\#0014) in Wake County, - # NC for 2017 (Note, for annual data, only the - # year portion of the bdate and edate are used and only whole - # years of data are returned. For example, bdate = 2017-12-31 and - # edate = 2018-01-01 will return full data for 2017 and 2018 ) - \dontrun{ - aqs_annualsummary_by_site(parameter = "44201", - bdate = as.Date("20170618", - format="\%Y\%m\%d"), - edate = as.Date("20190618", - format="\%Y\%m\%d"), - stateFIPS = "37", - countycode = "183", - sitenum = "0014" - ) - } -} -\seealso{ -Other Aggregate _by_site functions: -\code{\link{aqs_dailysummary_by_site}()}, -\code{\link{aqs_monitors_by_site}()}, -\code{\link{aqs_qa_annualperformanceeval_by_site}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_county}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_site}()}, -\code{\link{aqs_qa_blanks_by_site}()}, -\code{\link{aqs_qa_collocated_assessments_by_site}()}, -\code{\link{aqs_qa_flowrateaudit_by_site}()}, -\code{\link{aqs_qa_flowrateverification_by_site}()}, -\code{\link{aqs_qa_one_point_qc_by_site}()}, -\code{\link{aqs_qa_pep_audit_by_site}()}, -\code{\link{aqs_sampledata_by_site}()}, -\code{\link{aqs_services_by_site}()}, -\code{\link{aqs_transactionsample_by_site}()} -} -\concept{Aggregate _by_site functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_annualsummary_by_state.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_annualsummary_by_state.Rd deleted file mode 100644 index 23ed725..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_annualsummary_by_state.Rd +++ /dev/null @@ -1,110 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bystate.R -\name{aqs_annualsummary_by_state} -\alias{aqs_annualsummary_by_state} -\title{aqs_annualsummary_by_state} -\usage{ -aqs_annualsummary_by_state( - parameter, - bdate, - edate, - stateFIPS, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object that containing annual -summary data for the stateFIPS requested. A AQS_Data Mart_APIv2 is -a 2 item named list in which the first item ($Header) is a tibble -of header information from the AQS API and the second item ($Data -is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns multiple years of data where annual data is -aggregated at the state level. Returned is an annual summary -matching the input parameter and stateFIPS -provided for bdate - edate time frame. The data -returned is summarized at the annual level. Variables -returned include mean value, maxima, percentiles, and etc. If -return_header is FALSE (default) the object returned is a -tibble, if TRUE an AQS_API_v2 object. -} -\note{ -The AQS API only allows for a single year of annualsummary to be -retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# returns a tibble of all benzene annualy - # summaries from North Carolina collected for 1995 - \dontrun{aqs_annualsummary_by_state(parameter = "45201", - bdate = as.Date("19950515", - format="\%Y\%m\%d" - ), - edate = as.Date("19950515", - format = "\%Y\%m\%d" - ), - stateFIPS = "37" - ) - } -} -\seealso{ -Other Aggregate_by_state functions: -\code{\link{aqs_dailysummary_by_state}()}, -\code{\link{aqs_monitors_by_state}()}, -\code{\link{aqs_qa_blanks_by_state}()}, -\code{\link{aqs_qa_collocated_assessments_by_state}()}, -\code{\link{aqs_qa_flowrateaudit_by_state}()}, -\code{\link{aqs_qa_flowrateverification_by_state}()}, -\code{\link{aqs_qa_one_point_qc_by_state}()}, -\code{\link{aqs_qa_pep_audit_by_state}()}, -\code{\link{aqs_sampledata_by_state}()} -} -\concept{Aggregate_by_state functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_cbsas.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_cbsas.Rd deleted file mode 100644 index 2778a2e..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_cbsas.Rd +++ /dev/null @@ -1,31 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/RAQSAPIlistfunctions.R -\name{aqs_cbsas} -\alias{aqs_cbsas} -\title{aqs_cbsas} -\usage{ -aqs_cbsas(return_header = FALSE) -} -\arguments{ -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object of all Core Based -Statistical Areas (cbsa) and their cbsa_codes for constructing -other requests. -} -\description{ -\lifecycle{stable} -Returns a table of all Core Based Statistical Areas (cbsa) -and their associated cbsa_codes. for constructing other -requests. -} -\examples{ -# Returns a tibble of Core Based Statistical Areas (cbsas) - # and their respective cbsa codes - \dontrun{ aqs_cbsas() } -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_classes.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_classes.Rd deleted file mode 100644 index 60fce0a..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_classes.Rd +++ /dev/null @@ -1,30 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/RAQSAPIlistfunctions.R -\name{aqs_classes} -\alias{aqs_classes} -\title{aqs_classes} -\usage{ -aqs_classes(return_header = FALSE) -} -\arguments{ -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object of Parameter classes -(groups of parameters, i.e. "criteria" or "all"). -} -\description{ -\lifecycle{stable} -Returns a table of Parameter classes (groups of parameters, -i.e. "criteria" or "all"). The information from this function -can be used as input to other API calls. -} -\examples{ -# Returns a tibble of parameter classes (groups of parameters, i.e. - # "criteria" or all") - \dontrun{ aqs_classes() } -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_counties_by_state.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_counties_by_state.Rd deleted file mode 100644 index a2a68bb..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_counties_by_state.Rd +++ /dev/null @@ -1,35 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/RAQSAPIlistfunctions.R -\name{aqs_counties_by_state} -\alias{aqs_counties_by_state} -\title{aqs_counties_by_state} -\usage{ -aqs_counties_by_state(stateFIPS, return_header = FALSE) -} -\arguments{ -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zeros) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object of all counties in the -requested state. -} -\description{ -\lifecycle{stable} -Returns a table of all counties in within the -stateFIPS provided. -} -\examples{ - # Returns a tibble all the counties - # in North Carolina the county FIPS codes (county codes) for - # each. - \dontrun{aqs_counties_by_state(stateFIPS = "37")} -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_credentials.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_credentials.Rd deleted file mode 100644 index ded7a06..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_credentials.Rd +++ /dev/null @@ -1,40 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/setupfunctions.R -\name{aqs_credentials} -\alias{aqs_credentials} -\title{aqs_credentials} -\usage{ -aqs_credentials(username = NA_character_, key = NA_character_) -} -\arguments{ -\item{username}{a R character object which represents the email account that -will be used to connect to the AQS API.} - -\item{key}{the key used in conjunction with the username given to connect to -AQS Data Mart.} -} -\value{ -None -} -\description{ -\lifecycle{stable} -Sets the user credentials for the AQS API. This function -needs to be called once and only once every time this library -is re-loaded. Users must have a valid username and key which -can be obtained through the use of the aqs_sign_up function, -@seealso \code{\link[=aqs_sign_up]{aqs_sign_up()}} to sign up for AQS data mart -credentials. -} -\section{RAQSAPI setup functions}{ -NA -} - -\examples{ - #to authenticate an existing user the email address - # "John.Doe@myemail.com" and key = "MyKey" - # after calling this function please follow the instructions that are sent - # in the verification e-mail before proceeding. - \dontrun{aqs_credentials(username = "John.Doe@myemail.com", - key = "MyKey") - } -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_dailysummary_by_box.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_dailysummary_by_box.Rd deleted file mode 100644 index f88c76c..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_dailysummary_by_box.Rd +++ /dev/null @@ -1,116 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bybox.R -\name{aqs_dailysummary_by_box} -\alias{aqs_dailysummary_by_box} -\title{aqs_dailysummary_by_box} -\usage{ -aqs_dailysummary_by_box( - parameter, - bdate, - edate, - minlat, - maxlat, - minlon, - maxlon, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{minlat}{a R character object which represents the minimum latitude of -a geographic box. Decimal latitude with north begin -positive. Only data north of this latitude will be -returned.} - -\item{maxlat}{a R character object which represents the maximum latitude of -a geographic box. Decimal latitude with north begin -positive. Only data south of this latitude will be -returned.} - -\item{minlon}{a R character object which represents the minimum longitude -of a geographic box. Decimal longitude with east begin -positive. Only data east of this longitude will be -returned.} - -\item{maxlon}{a R character object which represents the maximum longitude -of a geographic box. Decimal longitude with east begin -positive. Only data west of this longitude will be -returned. Note that -80 is less than -70.} - -\item{cbdate}{a R date object which represents a "beginning date of last -change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two item -list that contains header information returned from -the API server mostly used for debugging purposes in -addition to the data requested.} -} -\value{ -a tibble or an AQS_Data_Mart_APIv2 S3 object that contains daily -summary statistics for the given parameter for an area bounded -within a latitude/longitude bounding box. An AQS_Data Mart_APIv2 is -a 2 item named list in which the first item ($Header) is a tibble -of header information from the AQS API and the second item ($Data) -is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a tibble or an AQS_Data Mart_APIv2 S3 -object containing daily summary data bounded within a -latitude/longitude bounding box -} -\note{ -The AQS API only allows for a single year of dailysummary to be -retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -#Returns a tibble of ozone daily summaries in the vicinity of - # central Alabama for the first two days of May 2015 - - \dontrun{aqs_dailysummary_by_box(parameter = "44201", - bdate = as.Date("20140501", - format = "\%Y\%m\%d" - ), - edate = as.Date("20160502", - format = "\%Y\%m\%d" - ), - mqinlat ="33.3", - maxlat = "33.6", - minlon = "-87.0", - maxlon = "-86.7" - ) - } -} -\concept{Aggregate_by_box functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_dailysummary_by_cbsa.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_dailysummary_by_cbsa.Rd deleted file mode 100644 index 7e06795..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_dailysummary_by_cbsa.Rd +++ /dev/null @@ -1,98 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bycbsa.R -\name{aqs_dailysummary_by_cbsa} -\alias{aqs_dailysummary_by_cbsa} -\title{aqs_dailysummary_by_cbsa} -\usage{ -aqs_dailysummary_by_cbsa( - parameter, - bdate, - edate, - cbsa_code, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{cbsa_code}{a R character object which represents the 5 digit AQS Core -Based Statistical Area code (the same as the census code, -with leading zeros)} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. If TRUE -returns a AQSAPI_v2 object which is a two item list that contains header -information returned from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object that contains daily -summary statistics for the given parameter for a single cbsa_code. -An AQS_Data Mart_APIv2 is a 2 item named list in which the first -item ($Header) is a tibble of header information from the AQS API -and the second item ($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a tibble or an AQS_Data Mart_APIv2 S3 -object containing daily summary data aggregated by cbsa -(Core Based Statistical Area) code. -} -\note{ -The AQS API only allows for a single year of dailysummary to be -retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# Returns a tibble of $NO_{2}$ daily summary - # data the for Charlotte-Concord-Gastonia, NC cbsa on - # Janurary 01, 2017 - \dontrun{aqs_dailysummary_by_cbsa(parameter = "42602", - bdate = as.Date("20170101", - format = "\%Y\%m\%d" - ), - edate = as.Date("20190101", - format = "\%Y\%m\%d" - ), - cbsa_code = "16740" - ) - } -} -\seealso{ -Other Aggregate _by_cbsa functions: -\code{\link{aqs_annualsummary_by_cbsa}()}, -\code{\link{aqs_monitors_by_cbsa}()}, -\code{\link{aqs_sampledata_by_cbsa}()} -} -\concept{Aggregate _by_cbsa functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_dailysummary_by_county.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_dailysummary_by_county.Rd deleted file mode 100644 index 22d26a0..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_dailysummary_by_county.Rd +++ /dev/null @@ -1,118 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bycounty.R -\name{aqs_dailysummary_by_county} -\alias{aqs_dailysummary_by_county} -\title{aqs_dailysummary_by_county} -\usage{ -aqs_dailysummary_by_county( - parameter, - bdate, - edate, - stateFIPS, - countycode, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be -returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object that contains daily -summary statistics for the given parameter for a single countycode -and stateFIPS combination. An AQS_Data Mart_APIv2 is a 2 item named -list in which the first item ($Header) is a tibble of header -information from the AQS API and the second item ($Data) is a -tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns multiple years of data where daily data is -aggregated at the site level. Returned is a daily summary -matching the input parameter, stateFIPS and county_code -provided for bdate - edate time frame. Variables returned include -mean value, maxima, percentiles, and etc. -} -\note{ -The AQS API only allows for a single year of dailysummary to be -retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# returns an aqs S3 object of daily summary FRM/FEM PM2.5 data - # for Wake County, NC between January and February 2016 - \dontrun{aqs_dailysummary_by_county(parameter = "88101", - bdate = as.Date("20160101", - format = "\%Y\%m\%d"), - edate = as.Date("20170228", - format = "\%Y\%m\%d"), - stateFIPS = "37", - countycode = "183" - ) - } -} -\seealso{ -Other Aggregate _by_county functions: -\code{\link{aqs_annualsummary_by_county}()}, -\code{\link{aqs_monitors_by_county}()}, -\code{\link{aqs_qa_annualperformanceeval_by_county}()}, -\code{\link{aqs_qa_blanks_by_county}()}, -\code{\link{aqs_qa_collocated_assessments_by_county}()}, -\code{\link{aqs_qa_flowrateaudit_by_county}()}, -\code{\link{aqs_qa_flowrateverification_by_county}()}, -\code{\link{aqs_qa_one_point_qc_by_county}()}, -\code{\link{aqs_qa_pep_audit_by_county}()}, -\code{\link{aqs_quarterlysummary_by_county}()}, -\code{\link{aqs_quarterlysummary_by_site}()}, -\code{\link{aqs_sampledata_by_county}()}, -\code{\link{aqs_transactionsample_by_county}()} -} -\concept{Aggregate _by_county functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_dailysummary_by_site.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_dailysummary_by_site.Rd deleted file mode 100644 index 5d44bb4..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_dailysummary_by_site.Rd +++ /dev/null @@ -1,126 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bysite.R -\name{aqs_dailysummary_by_site} -\alias{aqs_dailysummary_by_site} -\title{aqs_dailysummary_by_site} -\usage{ -aqs_dailysummary_by_site( - parameter, - bdate, - edate, - stateFIPS, - countycode, - sitenum, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{sitenum}{a R character object which represents the 4 digit site number -(with leading zeros) within the county and state being -requested.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object that contains daily -summary statistics for the given parameter for a single site. An -AQS_Data Mart_APIv2 is a 2 item named list in which the first item -($Header) is a tibble of header information from the AQS API and -the second item ($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns multiple years of data where dailysummary data is -aggregated at the site level. Returned is a daily summary -matching the input parameter stateFIPS, countycode, and sitenum -provided for bdate - edate time frame. Data is aggregated at the -state level. Variables returned include mean value, maxima, -percentiles, and etc. -} -\note{ -The AQS API only allows for a single year of dailysummary to be -retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -#Returns a tibble of daily summary ozone - # data for the Millbrook School site (\#0014) in Wake County, - # NC for June 18, 2017. - \dontrun{ - aqs_dailysummary_by_site(parameter = "44201", - bdate = as.Date("20160618", - format = "\%Y\%m\%d"), - edate = as.Date("20190618", - format = "\%Y\%m\%d"), - stateFIPS = "37", - countycode = "183", - sitenum = "0014" - ) - } -} -\seealso{ -Other Aggregate _by_site functions: -\code{\link{aqs_annualsummary_by_site}()}, -\code{\link{aqs_monitors_by_site}()}, -\code{\link{aqs_qa_annualperformanceeval_by_site}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_county}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_site}()}, -\code{\link{aqs_qa_blanks_by_site}()}, -\code{\link{aqs_qa_collocated_assessments_by_site}()}, -\code{\link{aqs_qa_flowrateaudit_by_site}()}, -\code{\link{aqs_qa_flowrateverification_by_site}()}, -\code{\link{aqs_qa_one_point_qc_by_site}()}, -\code{\link{aqs_qa_pep_audit_by_site}()}, -\code{\link{aqs_sampledata_by_site}()}, -\code{\link{aqs_services_by_site}()}, -\code{\link{aqs_transactionsample_by_site}()} -} -\concept{Aggregate _by_site functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_dailysummary_by_state.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_dailysummary_by_state.Rd deleted file mode 100644 index fa9e91a..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_dailysummary_by_state.Rd +++ /dev/null @@ -1,107 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bystate.R -\name{aqs_dailysummary_by_state} -\alias{aqs_dailysummary_by_state} -\title{aqs_dailysummary_by_state} -\usage{ -aqs_dailysummary_by_state( - parameter, - bdate, - edate, - stateFIPS, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two item -list that contains header information returned from -the API server mostly used for debugging purposes in -addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object that contains daily -summary statistics for the given parameter for a single stateFIPS. -An AQS_Data Mart_APIv2 is a 2 item named list in which the first -item ($Header) is a tibble of header information from the AQS API -and the second item ($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns multiple years of data where daily data is -aggregated at the state level. Returned is a daily summary -matching the input parameter and stateFIPS provided for bdate - edate -time frame. Data is aggregated at the state level. Variables returned -include mean value, maxima, percentiles, and etc. -} -\note{ -The AQS API only allows for a single year of dailysummary to be -retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# returns a tibble of all benzene daily - # summaries from North Carolina collected on May 15th, 1995 - \dontrun{aqs_dailysummary_by_state(parameter = "45201", - bdate = as.Date("19950515", - format="\%Y\%m\%d" - ), - edate = as.Date("19970515", - format = "\%Y\%m\%d" - ), - stateFIPS = "37" - ) - } -} -\seealso{ -Other Aggregate_by_state functions: -\code{\link{aqs_annualsummary_by_state}()}, -\code{\link{aqs_monitors_by_state}()}, -\code{\link{aqs_qa_blanks_by_state}()}, -\code{\link{aqs_qa_collocated_assessments_by_state}()}, -\code{\link{aqs_qa_flowrateaudit_by_state}()}, -\code{\link{aqs_qa_flowrateverification_by_state}()}, -\code{\link{aqs_qa_one_point_qc_by_state}()}, -\code{\link{aqs_qa_pep_audit_by_state}()}, -\code{\link{aqs_sampledata_by_state}()} -} -\concept{Aggregate_by_state functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_fields_by_service.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_fields_by_service.Rd deleted file mode 100644 index 4414882..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_fields_by_service.Rd +++ /dev/null @@ -1,36 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/RAQSAPIlistfunctions.R -\name{aqs_fields_by_service} -\alias{aqs_fields_by_service} -\title{aqs_fieldsbyservice} -\usage{ -aqs_fields_by_service(service, return_header = FALSE) -} -\arguments{ -\item{service}{a string which represents the services provided by the AQS -API. For a list of available services -@seealso \url{https://aqs.epa.gov/aqsweb/documents/data_api.html#services - }} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object with containing the list -and definitions of fields requested service -} -\description{ -\lifecycle{stable} -Returns a tibble or an AQS_Data Mart_APIv2 S3 -object with the list and definitions of fields in the -service requested. -} -\examples{ -# Returns a tibble containing a list and definitions - # of fields in the Sample Data service - \dontrun{aqs_fieldsbyservice(service = "sampleData")} - -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_isavailable.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_isavailable.Rd deleted file mode 100644 index a5d56aa..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_isavailable.Rd +++ /dev/null @@ -1,32 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/RAQSAPIlistfunctions.R -\name{aqs_isavailable} -\alias{aqs_isavailable} -\title{aqs_isavailable} -\usage{ -aqs_isavailable(return_header = FALSE) -} -\arguments{ -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object which details the status -of the AQS API (The status information is located in the header) -} -\description{ -\lifecycle{stable} -returns a tibble or an AQS_Data Mart_APIv2 S3 object -explaining the status of the AQS API. -} -\section{list functions}{ -NA -} - -\examples{ - # Check if the AQS API is up, running and accepting requests. - \dontrun{ aqs_isAvailable() } -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_knownissues.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_knownissues.Rd deleted file mode 100644 index 7886a3e..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_knownissues.Rd +++ /dev/null @@ -1,32 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/RAQSAPIlistfunctions.R -\name{aqs_knownissues} -\alias{aqs_knownissues} -\title{aqs_knownissues} -\usage{ -aqs_knownissues(return_header = FALSE) -} -\arguments{ -\item{return_header}{If FALSE (default) only returns data requested. If TRUE -returns a AQSAPI_v2 object which is a two item list that contains header -information returned from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object that contains -information involving known issues with the Data Mart API. -} -\description{ -\lifecycle{stable} -Returns a table of any known issues with system functionality -or the data. These are usually issues that have been -identified internally and will require some time to correct -in Data Mart or the API. This function implements a direct -API call to Data Mart and returns data directly from the API. -Issues returned via this function do not include any issues -from the RAQSAPI R package. -} -\examples{ - # Retrieve a tibble of known issues directly from the AQS data mart API - \dontrun{aqs_knownissues()} -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_mas.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_mas.Rd deleted file mode 100644 index 9c53e6f..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_mas.Rd +++ /dev/null @@ -1,29 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/RAQSAPIlistfunctions.R -\name{aqs_mas} -\alias{aqs_mas} -\title{aqs_mas} -\usage{ -aqs_mas(return_header = FALSE) -} -\arguments{ -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object of monitoring agencies -and their associated agency code. -} -\description{ -\lifecycle{stable} -Returns a table of monitoring agencies (MA). -} -\examples{ -# Returns a tibble or an AQS_Data Mart_APIv2 S3 object - # of monitoring agencies and their respective - # monitoring agency codes. - \dontrun{aqs_mas()} -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_metadata_service.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_metadata_service.Rd deleted file mode 100644 index 93f0c99..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_metadata_service.Rd +++ /dev/null @@ -1,32 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/AQSAPI_helperfunctions.R -\name{aqs_metadata_service} -\alias{aqs_metadata_service} -\title{aqs_metadata_service} -\usage{ -aqs_metadata_service( - filter, - service = NA_character_, - AQS_domain = "aqs.epa.gov" -) -} -\arguments{ -\item{filter}{a character string representing the filter being applied} - -\item{service}{a character string representing the service} - -\item{AQS_domain}{a R string object containing the domain that should be -used in constructing the API call.} -} -\value{ -a AQS_DATAMART_APIv2 S3 object that is the return value from the -AQS API. A AQS_DATAMART_APIv2 is a 2 item named list in which the -first item ($Header) is a tibble of header information from the -AQS API and the second item ($Data) is a tibble of the data -returned. -} -\description{ -A helper function for functions which use the metaData service -from the AQS API. This function is not intended to be called -directly by the end user -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_monitors_by_box.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_monitors_by_box.Rd deleted file mode 100644 index b69b65e..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_monitors_by_box.Rd +++ /dev/null @@ -1,92 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bybox.R -\name{aqs_monitors_by_box} -\alias{aqs_monitors_by_box} -\title{aqs_monitors_by_box} -\usage{ -aqs_monitors_by_box( - parameter, - bdate, - edate, - minlat, - maxlat, - minlon, - maxlon, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{minlat}{a R character object which represents the minimum latitude of -a geographic box. Decimal latitude with north begin -positive. Only data north of this latitude will be -returned.} - -\item{maxlat}{a R character object which represents the maximum latitude of -a geographic box. Decimal latitude with north begin -positive. Only data south of this latitude will be -returned.} - -\item{minlon}{a R character object which represents the minimum longitude -of a geographic box. Decimal longitude with east begin -positive. Only data east of this longitude will be -returned.} - -\item{maxlon}{a R character object which represents the maximum longitude -of a geographic box. Decimal longitude with east begin -positive. Only data west of this longitude will be -returned. Note that -80 is less than -70.} - -\item{return_header}{If FALSE (default) only returns data requested. If TRUE -returns a AQSAPI_v2 object which is a two item list that contains header -information returned from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object of monitors from a -latitude/longitude bounding box (_by_box). -} -\description{ -\lifecycle{stable} -Returns a table of monitors and related metadata sites with the provided -parameter, aggregated by latitude/longitude bounding box (_by_box) for -bdate - edate time frame. -} -\note{ -All monitors that operated between the bdate and edate will be returned -} -\section{by_box aggregate functions}{ -NA -} - -\examples{ -# Returns a tibble of all ozone - # monitors in the vicinity of central Alabama that operated in - # 1995 - \dontrun{aqs_monitors_by_box(parameter="44201", - bdate=as.Date("19950101", - format="\%Y\%m\%d"), - edate=as.Date("19951231", - format="\%Y\%m\%d"), - minlat="33.3", - maxlat="33.6", - minlon="-87.0", - maxlon="-86.7" - ) - } -} -\seealso{ -Other Aggregate _by_box functions: -\code{\link{aqs_annualsummary_by_box}()}, -\code{\link{aqs_sampledata_by_box}()} -} -\concept{Aggregate _by_box functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_monitors_by_cbsa.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_monitors_by_cbsa.Rd deleted file mode 100644 index c701031..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_monitors_by_cbsa.Rd +++ /dev/null @@ -1,91 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bycbsa.R -\name{aqs_monitors_by_cbsa} -\alias{aqs_monitors_by_cbsa} -\title{aqs_monitors_by_cbsa} -\usage{ -aqs_monitors_by_cbsa( - parameter, - bdate, - edate, - cbsa_code, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{cbsa_code}{a R character object which represents the 5 digit AQS Core -Based Statistical Area code (the same as the census code, -with leading zeros)} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. If TRUE -returns a AQSAPI_v2 object which is a two item list -that contains header information returned from the -API server mostly used for debugging purposes in -addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object that is the return value -from the AQS API. A AQS_Data Mart_APIv2 object is a 2 item named -list in which the first item ($Header) is a tibble of header -information from the AQS API and the second item ($Data) is a -tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a table of monitors at all sites with the provided -parameter, aggregated by Core Based Statistical Area (CBSA) for -bdate - edate time frame. -} -\note{ -All monitors that operated between the bdate and edate will be returned -} -\section{by_cbsa (By Core Based Statistical Area, as defined by the US Census Bureau) aggregate functions}{ -NA -} - -\examples{ -# returns a tibble of $NO_{2}$ monitors - # for Charlotte-Concord-Gastonia, NC cbsa that were operating - # on Janurary 01, 2017 - \dontrun{aqs_monitors_by_cbsa(parameter="42602", - bdate=as.Date("20170101", - format="\%Y\%m\%d"), - edate=as.Date("20170101", - format="\%Y\%m\%d"), - cbsa_code="16740" - ) - } -} -\seealso{ -Other Aggregate _by_cbsa functions: -\code{\link{aqs_annualsummary_by_cbsa}()}, -\code{\link{aqs_dailysummary_by_cbsa}()}, -\code{\link{aqs_sampledata_by_cbsa}()} -} -\concept{Aggregate _by_cbsa functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_monitors_by_county.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_monitors_by_county.Rd deleted file mode 100644 index 7f69414..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_monitors_by_county.Rd +++ /dev/null @@ -1,104 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bycounty.R -\name{aqs_monitors_by_county} -\alias{aqs_monitors_by_county} -\title{aqs_monitors_by_county} -\usage{ -aqs_monitors_by_county( - parameter, - bdate, - edate, - stateFIPS, - countycode, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be -returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two item -list that contains header information returned from -the API server mostly used for debugging purposes in -addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object of monitors from a -selected county -} -\description{ -\lifecycle{stable} -Returns a table of monitors and related metadata at sites with the -provided parameter, stateFIPS and county_code for -bdate - edate time frame. -} -\note{ -All monitors that operated between the bdate and edate will be returned -} -\section{by_county aggregate functions}{ -NA -} - -\examples{ -# returns an aqs_v2 S3 object containing all SO2 monitors in - # Hawaii County, HI that were operating between May 01-02, 2015. - \dontrun{aqs_monitors_by_county(parameter="42401", - bdate=as.Date("20150501", format="\%Y\%m\%d"), - edate=as.Date("20150502", format="\%Y\%m\%d"), - stateFIPS="15", - countycode="001" - ) - } -} -\seealso{ -Other Aggregate _by_county functions: -\code{\link{aqs_annualsummary_by_county}()}, -\code{\link{aqs_dailysummary_by_county}()}, -\code{\link{aqs_qa_annualperformanceeval_by_county}()}, -\code{\link{aqs_qa_blanks_by_county}()}, -\code{\link{aqs_qa_collocated_assessments_by_county}()}, -\code{\link{aqs_qa_flowrateaudit_by_county}()}, -\code{\link{aqs_qa_flowrateverification_by_county}()}, -\code{\link{aqs_qa_one_point_qc_by_county}()}, -\code{\link{aqs_qa_pep_audit_by_county}()}, -\code{\link{aqs_quarterlysummary_by_county}()}, -\code{\link{aqs_quarterlysummary_by_site}()}, -\code{\link{aqs_sampledata_by_county}()}, -\code{\link{aqs_transactionsample_by_county}()} -} -\concept{Aggregate _by_county functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_monitors_by_site.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_monitors_by_site.Rd deleted file mode 100644 index e0c2af0..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_monitors_by_site.Rd +++ /dev/null @@ -1,116 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bysite.R -\name{aqs_monitors_by_site} -\alias{aqs_monitors_by_site} -\title{aqs_monitors_by_site} -\usage{ -aqs_monitors_by_site( - parameter, - bdate, - edate, - stateFIPS, - countycode, - sitenum, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{sitenum}{a R character object which represents the 4 digit site number -(with leading zeros) within the county and state being -requested.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object of monitors from a -selected stateFIPS, county, and sitenum combination. -} -\description{ -\lifecycle{stable} -Returns a table of monitors and related metadata at sites with the -provided parameter, stateFIPS, county_code, and sitenum for -bdate - edate time frame. -} -\note{ -All monitors that operated between the bdate and edate will be returned -} -\section{by_site aggregate functions}{ -NA -} - -\examples{ - #Returns a tibble of the SO2 monitors at Hawaii - # Volcanoes NP site (\#0007) in Hawaii County, HI that were operating - # between May 1 , 2015-2019. (Note, all monitors that operated between the - # bdate and edate will be returned). - \dontrun{ - aqs_monitors_by_site(parameter = "42401", - bdate = as.Date("20150501", - format="\%Y\%m\%d"), - edate = as.Date("20190501", - format="\%Y\%m\%d"), - stateFIPS = "15", - countycode = "001", - sitenum = "0007" - ) - } - -} -\seealso{ -Other Aggregate _by_site functions: -\code{\link{aqs_annualsummary_by_site}()}, -\code{\link{aqs_dailysummary_by_site}()}, -\code{\link{aqs_qa_annualperformanceeval_by_site}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_county}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_site}()}, -\code{\link{aqs_qa_blanks_by_site}()}, -\code{\link{aqs_qa_collocated_assessments_by_site}()}, -\code{\link{aqs_qa_flowrateaudit_by_site}()}, -\code{\link{aqs_qa_flowrateverification_by_site}()}, -\code{\link{aqs_qa_one_point_qc_by_site}()}, -\code{\link{aqs_qa_pep_audit_by_site}()}, -\code{\link{aqs_sampledata_by_site}()}, -\code{\link{aqs_services_by_site}()}, -\code{\link{aqs_transactionsample_by_site}()} -} -\concept{Aggregate _by_site functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_monitors_by_state.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_monitors_by_state.Rd deleted file mode 100644 index 6b49509..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_monitors_by_state.Rd +++ /dev/null @@ -1,94 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bystate.R -\name{aqs_monitors_by_state} -\alias{aqs_monitors_by_state} -\title{aqs_monitors_by_state} -\usage{ -aqs_monitors_by_state( - parameter, - bdate, - edate, - stateFIPS, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two item -list that contains header information returned from -the API server mostly used for debugging purposes in -addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object of monitors from the -selected state -} -\description{ -\lifecycle{stable} -Returns a table of monitors and related metadata at sites with the -provided parameter, and stateFIPS for bdate - edate time frame. -} -\note{ -All monitors that operated between the bdate and edate will be returned -} -\section{by_state aggregate functions}{ -NA -} - -\examples{ -# returns a tibble of SO2 monitors in Hawaii - # that were operating on May 01, 2017 - \dontrun{aqs_monitors_by_state(parameter="88101", - bdate=as.Date("20170101", - format="\%Y\%m\%d"), - edate=as.Date("20171231", - format="\%Y\%m\%d"), - stateFIPS="01" - ) - } - -} -\seealso{ -Other Aggregate_by_state functions: -\code{\link{aqs_annualsummary_by_state}()}, -\code{\link{aqs_dailysummary_by_state}()}, -\code{\link{aqs_qa_blanks_by_state}()}, -\code{\link{aqs_qa_collocated_assessments_by_state}()}, -\code{\link{aqs_qa_flowrateaudit_by_state}()}, -\code{\link{aqs_qa_flowrateverification_by_state}()}, -\code{\link{aqs_qa_one_point_qc_by_state}()}, -\code{\link{aqs_qa_pep_audit_by_state}()}, -\code{\link{aqs_sampledata_by_state}()} -} -\concept{Aggregate_by_state functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_parameters_by_class.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_parameters_by_class.Rd deleted file mode 100644 index 7067361..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_parameters_by_class.Rd +++ /dev/null @@ -1,35 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/RAQSAPIlistfunctions.R -\name{aqs_parameters_by_class} -\alias{aqs_parameters_by_class} -\title{aqs_parameters_by_class} -\usage{ -aqs_parameters_by_class(class, return_header = FALSE) -} -\arguments{ -\item{class}{a R character object that represents the class requested, -@seealso \code{\link[=aqs_classes]{aqs_classes()}} for retrieving -available classes. The class R character object must be a -valid class as returned from aqs_classes(). The class must -be an exact match to what is returned from aqs_classes() -(case sensitive).} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing the -parameters associated with the class requested. NULL is returned -for classes not found. -} -\description{ -\lifecycle{stable} -Returns parameters associated with the input class. -} -\examples{ -# Returns a tibble of AQS parameters in the criteria class - \dontrun{ aqs_parameters_by_class(class = "CRITERIA") } -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_pqaos.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_pqaos.Rd deleted file mode 100644 index b9e7fc1..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_pqaos.Rd +++ /dev/null @@ -1,29 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/RAQSAPIlistfunctions.R -\name{aqs_pqaos} -\alias{aqs_pqaos} -\title{aqs_pqaos} -\usage{ -aqs_pqaos(return_header = FALSE) -} -\arguments{ -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object of pqaos and -their associated pqao code. -} -\description{ -\lifecycle{stable} -Returns a table of primary quality assurance -organizations (pqaos). -} -\examples{ -# Returns a tibble of primary quality assurance - # organizations (pqaos) - \dontrun{ aqs_pqaos() } -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceeval_by_MA.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceeval_by_MA.Rd deleted file mode 100644 index 2760e9b..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceeval_by_MA.Rd +++ /dev/null @@ -1,88 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/byma.R -\name{aqs_qa_annualperformanceeval_by_MA} -\alias{aqs_qa_annualperformanceeval_by_MA} -\title{aqs_qa_annualperformanceeval_by_MA} -\usage{ -aqs_qa_annualperformanceeval_by_MA( - parameter, - bdate, - edate, - MA_code, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be -returned.} - -\item{MA_code}{a R character object which represents the 4 digit AQS -Monitoring Agency code (with leading zeroes).} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object of quality assurance -performance evaluation data. for all monitoring sites for with -the MA_code requested for the time frame between bdate and edate. -An AQS_Data_Mart_APIv2 is a 2 item named list in which the first -item ($Header) is a tibble of header information from the AQS API -and the second item ($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns quality assurance performance evaluation data - aggregated by -by Monitoring agency (MA) for a parameter -code aggregated by matching input parameter and MA_code for the -time frame between bdate and edate. -} -\note{ -The AQS API only allows for a single year of quality assurance -Annual Performance Evaluation data to be retrieved at a time. This -function conveniently extracts date information from the bdate -and edate parameters then makes repeated calls to the AQSAPI -retrieving a maximum of one calendar year of data at a time. Each -calendar year of data requires a separate API call so multiple years -of data will require multiple API calls. As the number of years of -data being requested increases so does the length of time that it -will take to retrieve results. There is also a 5 second wait time -inserted between successive API calls to prevent overloading the API -server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ - # Returns a tibble containing annual performance evaluation data - # for ozone where the monitoring agency is the Alabama Department - # of Environmental Management (MA_code 0013). - \dontrun{aqs_qa_annualperformanceeval_by_MA(parameter = "44201", - bdate = as.Date("20170101", - format = "\%Y\%m\%d"), - edate = as.Date("20171231", - format = "\%Y\%m\%d"), - MA_code = "0013" - ) - } -} -\seealso{ -Other Aggregate _by_MA functions: -\code{\link{aqs_qa_annualperformanceevaltransaction_by_MA}()}, -\code{\link{aqs_qa_blanks_by_MA}()}, -\code{\link{aqs_qa_collocated_assessments_by_MA}()}, -\code{\link{aqs_qa_flowrateaudit_by_MA}()}, -\code{\link{aqs_qa_flowrateverification_by_MA}()}, -\code{\link{aqs_qa_one_point_qc_by_MA}()}, -\code{\link{aqs_qa_pep_audit_by_MA}()} -} -\concept{Aggregate _by_MA functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceeval_by_county.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceeval_by_county.Rd deleted file mode 100644 index a7b30b7..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceeval_by_county.Rd +++ /dev/null @@ -1,104 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bycounty.R -\name{aqs_qa_annualperformanceeval_by_county} -\alias{aqs_qa_annualperformanceeval_by_county} -\title{aqs_qa_annualperformanceeval_by_county} -\usage{ -aqs_qa_annualperformanceeval_by_county( - parameter, - bdate, - edate, - stateFIPS, - countycode, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be -returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object of quality assurance -performance evaluation data. for single monitoring site for the -sitenum, countycode and stateFIPS requested for the time frame -between bdate and edate. An AQS_Data_Mart_APIv2 is a 2 item named -list in which the first item ($Header) is a tibble of header -information from the AQS API and the second item ($Data) is a -tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns AQS submissions transaction format (RD) of the annual -performance evaluation data (raw). Includes data pairs for -QA - aggregated by county for a parameter code aggregated by -matching input parameter, countycode and stateFIPS -provided for bdate - edate time frame. -} -\note{ -The AQS API only allows for a single year of quality assurance -Annual Performance Evaluation data to be retrieved at a time. This -function conveniently extracts date information from the bdate -and edate parameters then makes repeated calls to the AQSAPI -retrieving a maximum of one calendar year of data at a time. Each -calendar year of data requires a separate API call so multiple years -of data will require multiple API calls. As the number of years of -data being requested increases so does the length of time that it -will take to retrieve results. There is also a 5 second wait time -inserted between successive API calls to prevent overloading the API -server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# Returns a tibble containing annual performance evaluation data - # (raw) for ozone in Baldwin County, AL for 2017 in RD format. - \dontrun{ aqs_qa_annualperformanceeval_by_county(parameter = "44201", - bdate = as.Date("20170101", - format = "\%Y\%m\%d"), - edate = as.Date("20171231", - format = "\%Y\%m\%d"), - stateFIPS = "01", - countycode = "003" - ) - } -} -\seealso{ -Other Aggregate _by_county functions: -\code{\link{aqs_annualsummary_by_county}()}, -\code{\link{aqs_dailysummary_by_county}()}, -\code{\link{aqs_monitors_by_county}()}, -\code{\link{aqs_qa_blanks_by_county}()}, -\code{\link{aqs_qa_collocated_assessments_by_county}()}, -\code{\link{aqs_qa_flowrateaudit_by_county}()}, -\code{\link{aqs_qa_flowrateverification_by_county}()}, -\code{\link{aqs_qa_one_point_qc_by_county}()}, -\code{\link{aqs_qa_pep_audit_by_county}()}, -\code{\link{aqs_quarterlysummary_by_county}()}, -\code{\link{aqs_quarterlysummary_by_site}()}, -\code{\link{aqs_sampledata_by_county}()}, -\code{\link{aqs_transactionsample_by_county}()} -} -\concept{Aggregate _by_county functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceeval_by_pqao.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceeval_by_pqao.Rd deleted file mode 100644 index 34cd486..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceeval_by_pqao.Rd +++ /dev/null @@ -1,89 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bypqao.R -\name{aqs_qa_annualperformanceeval_by_pqao} -\alias{aqs_qa_annualperformanceeval_by_pqao} -\title{aqs_qa_annualperformanceeval_by_pqao} -\usage{ -aqs_qa_annualperformanceeval_by_pqao( - parameter, - bdate, - edate, - pqao_code, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{pqao_code}{a R character object which represents the 4 digit AQS -Primary Quality Assurance Organization code -(with leading zeroes).} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object of quality assurance -performance evaluation data. for single monitoring site for the -pqao_code requested for the time frame -between bdate and edate. An AQS_Data_Mart_APIv2 is a 2 item named -list in which the first item ($Header) is a tibble of header -information from the AQS API and the second item ($Data) is a -tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns quality assurance performance evaluation data - aggregated by -Primary Quality Assurance Organization (PQAO) for a parameter -code aggregated by matching input parameter and pqao_code for the -time frame between bdate and edate. -} -\note{ -The AQS API only allows for a single year of quality assurance -Annual Performance Evaluation data to be retrieved at a time. This -function conveniently extracts date information from the bdate -and edate parameters then makes repeated calls to the AQSAPI -retrieving a maximum of one calendar year of data at a time. Each -calendar year of data requires a separate API call so multiple years -of data will require multiple API calls. As the number of years of -data being requested increases so does the length of time that it -will take to retrieve results. There is also a 5 second wait time -inserted between successive API calls to prevent overloading the API -server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# Returns a tibble containing annual performance evaluation data - # for ozone where the PQAO is the Alabamaba Department of - # Environmental Management (pqao_code 0013). - \dontrun{ aqs_qa_annualperformanceeval_by_pqao(parameter = "44201", - bdate = as.Date("20170101", - format = "\%Y\%m\%d"), - edate = as.Date("20171231", - format = "\%Y\%m\%d"), - pqao_code = "0013" - ) - } -} -\seealso{ -Other Aggregate _by_pqao functions: -\code{\link{aqs_qa_annualperformanceevaltransaction_by_pqao}()}, -\code{\link{aqs_qa_blanks_by_pqao}()}, -\code{\link{aqs_qa_collocated_assessments_by_pqao}()}, -\code{\link{aqs_qa_flowrateaudit_by_pqao}()}, -\code{\link{aqs_qa_flowrateverification_by_pqao}()}, -\code{\link{aqs_qa_one_point_qc_by_pqao}()}, -\code{\link{aqs_qa_pep_audit_by_pqao}()} -} -\concept{Aggregate _by_pqao functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceeval_by_site.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceeval_by_site.Rd deleted file mode 100644 index d75815f..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceeval_by_site.Rd +++ /dev/null @@ -1,125 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bysite.R -\name{aqs_qa_annualperformanceeval_by_site} -\alias{aqs_qa_annualperformanceeval_by_site} -\title{aqs_qa_annualperformanceeval_by_site} -\usage{ -aqs_qa_annualperformanceeval_by_site( - parameter, - bdate, - edate, - stateFIPS, - countycode, - sitenum, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{sitenum}{a R character object which represents the 4 digit site number -(with leading zeros) within the county and state being -requested.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object of quality assurance -performance evaluation data. for single monitoring site for the -sitenum, countycode and stateFIPS requested for the time frame -between bdate and edate. An AQS_Data_Mart_APIv2 is a 2 item named -list in which the first item ($Header) is a tibble of header -information from the AQS API and the second item ($Data) is a -tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns quality assurance performance evaluation data - aggregated by -site for a parameter code aggregated by matching input -parameter, sitenum, countycode and stateFIPS provided for -bdate - edate time frame. -} -\note{ -The AQS API only allows for a single year of quality assurance -Annual Performance Evaluation data to be retrieved at a time. This -function conveniently extracts date information from the bdate -and edate parameters then makes repeated calls to the AQSAPI -retrieving a maximum of one calendar year of data at a time. Each -calendar year of data requires a separate API call so multiple years -of data will require multiple API calls. As the number of years of -data being requested increases so does the length of time that it -will take to retrieve results. There is also a 5 second wait time -inserted between successive API calls to prevent overloading the API -server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -#Returns a tibble containing annual performance evaluation data for - # ozone at the Fairhope site in Baldwin County, AL for 2017 - \dontrun{ aqs_qa_annualperformanceeval_by_site(parameter = "44201", - bdate = as.Date("20170101", - format = "\%Y\%m\%d"), - edate = as.Date("20171231", - format = "\%Y\%m\%d"), - stateFIPS = "01", - countycode = "003", - sitenum = "0010" - ) - } -} -\seealso{ -Other Aggregate _by_site functions: -\code{\link{aqs_annualsummary_by_site}()}, -\code{\link{aqs_dailysummary_by_site}()}, -\code{\link{aqs_monitors_by_site}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_county}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_site}()}, -\code{\link{aqs_qa_blanks_by_site}()}, -\code{\link{aqs_qa_collocated_assessments_by_site}()}, -\code{\link{aqs_qa_flowrateaudit_by_site}()}, -\code{\link{aqs_qa_flowrateverification_by_site}()}, -\code{\link{aqs_qa_one_point_qc_by_site}()}, -\code{\link{aqs_qa_pep_audit_by_site}()}, -\code{\link{aqs_sampledata_by_site}()}, -\code{\link{aqs_services_by_site}()}, -\code{\link{aqs_transactionsample_by_site}()} -} -\concept{Aggregate _by_site functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceeval_by_state.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceeval_by_state.Rd deleted file mode 100644 index 96dcf18..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceeval_by_state.Rd +++ /dev/null @@ -1,88 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bystate.R -\name{aqs_qa_annualperformanceeval_by_state} -\alias{aqs_qa_annualperformanceeval_by_state} -\title{aqs_qa_annualperformanceeval_by_state} -\usage{ -aqs_qa_annualperformanceeval_by_state( - parameter, - bdate, - edate, - stateFIPS, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object of quality assurance -performance evaluation data. for single monitoring site for the -sitenum, countycode and stateFIPS requested for the time frame -between bdate and edate. An AQS_Data_Mart_APIv2 is a 2 item named -list in which the first item ($Header) is a tibble of header -information from the AQS API and the second item ($Data) is a -tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns quality assurance performance evaluation data - aggregated by -state for a parameter code aggregated by matching input -parameter, countycode and stateFIPS provided for -bdate - edate time frame. -} -\note{ -The AQS API only allows for a single year of quality assurance -Annual Performance Evaluation data to be retrieved at a time. This -function conveniently extracts date information from the bdate -and edate parameters then makes repeated calls to the AQSAPI -retrieving a maximum of one calendar year of data at a time. Each -calendar year of data requires a separate API call so multiple years -of data will require multiple API calls. As the number of years of -data being requested increases so does the length of time that it -will take to retrieve results. There is also a 5 second wait time -inserted between successive API calls to prevent overloading the API -server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# Returns a tibble containing annual performance evaluation - # data for ozone in Alabamba for 2017. - \dontrun{ aqs_qa_annualperformanceeval_by_state(parameter = "44201", - bdate = as.Date("20170101", - format = "\%Y\%m\%d"), - edate = as.Date("20171231", - format = "\%Y\%m\%d"), - stateFIPS = "01" - ) - } -} -\seealso{ -Other Aggregate _by_state functions: -\code{\link{aqs_qa_annualperformanceevaltransaction_by_state}()}, -\code{\link{aqs_quarterlysummary_by_box}()}, -\code{\link{aqs_quarterlysummary_by_cbsa}()}, -\code{\link{aqs_quarterlysummary_by_state}()}, -\code{\link{aqs_transactionsample_by_MA}()}, -\code{\link{aqs_transactionsample_by_state}()} -} -\concept{Aggregate _by_state functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceevaltransaction_by_MA.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceevaltransaction_by_MA.Rd deleted file mode 100644 index 2050f75..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceevaltransaction_by_MA.Rd +++ /dev/null @@ -1,90 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/byma.R -\name{aqs_qa_annualperformanceevaltransaction_by_MA} -\alias{aqs_qa_annualperformanceevaltransaction_by_MA} -\title{aqs_qa_annualperformanceevaltransaction_by_MA} -\usage{ -aqs_qa_annualperformanceevaltransaction_by_MA( - parameter, - bdate, - edate, - MA_code, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be -returned.} - -\item{MA_code}{a R character object which represents the 4 digit AQS -Monitoring Agency code (with leading zeroes).} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object of quality assurance -performance evaluation data in the AQS submissions transaction -format (RD)for all sites matching the MA_code requested for the -time frame between bdate and edate. An AQS_Data_Mart_APIv2 is a 2 -item named list in which the first item ($Header) is a tibble of -header information from the AQS API and the second item ($Data) is -a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns AQS submissions transaction format (RD) of the annual -performance evaluation data (raw). Includes data pairs for -QA - aggregated by Monitoring agency (MA) -for a parameter code aggregated by matching input parameter and -MA_code provided for bdate - edate time frame. -} -\note{ -The AQS API only allows for a single year of quality assurance -Annual Performance Evaluations transaction data to be retrieved at a -time. This function conveniently extracts date information from the -bdate and edate parameters then makes repeated calls to the AQSAPI -retrieving a maximum of one calendar year of data at a time. Each -calendar year of data requires a separate API call so multiple years -of data will require multiple API calls. As the number of years of -data being requested increases so does the length of time that it -will take to retrieve results. There is also a 5 second wait time -inserted between successive API calls to prevent overloading the API -server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# Returns a tibble containing annual performance evaluation data - # for ozone in where the MA is the Alabama Department of - # Environmental Management (MA_code 0013) for 2017 in RD format. - \dontrun{aqs_qa_annualperformanceevaltransaction_by_MA(parameter = "44201", - bdate = as.Date("20170101", - format = "\%Y\%m\%d"), - edate = as.Date("20171231", - format = "\%Y\%m\%d"), - MA_code = "0013" - ) - } -} -\seealso{ -Other Aggregate _by_MA functions: -\code{\link{aqs_qa_annualperformanceeval_by_MA}()}, -\code{\link{aqs_qa_blanks_by_MA}()}, -\code{\link{aqs_qa_collocated_assessments_by_MA}()}, -\code{\link{aqs_qa_flowrateaudit_by_MA}()}, -\code{\link{aqs_qa_flowrateverification_by_MA}()}, -\code{\link{aqs_qa_one_point_qc_by_MA}()}, -\code{\link{aqs_qa_pep_audit_by_MA}()} -} -\concept{Aggregate _by_MA functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceevaltransaction_by_county.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceevaltransaction_by_county.Rd deleted file mode 100644 index b2ddf55..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceevaltransaction_by_county.Rd +++ /dev/null @@ -1,105 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bycounty.R -\name{aqs_qa_annualperformanceevaltransaction_by_county} -\alias{aqs_qa_annualperformanceevaltransaction_by_county} -\title{aqs_qa_annualperformanceevaltransaction_by_site} -\usage{ -aqs_qa_annualperformanceevaltransaction_by_county( - parameter, - bdate, - edate, - stateFIPS, - countycode, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be -returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object of quality assurance -performance evaluation data in the RD format for a single -monitoring site for the countycode and stateFIPS requested -for the time frame between bdate and edate in the AQS. An -AQS_Data_Mart_APIv2 is a 2 item named list in which the first item -($Header) is a tibble of header information from the AQS API and -the second item ($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns AQS submissions transaction format (RD) of the annual -performance evaluation data (raw). Includes data pairs for -QA - aggregated by site for a parameter code aggregated by matching -input parameter, countycode and stateFIPS provided for -bdate - edate time frame. -} -\note{ -The AQS API only allows for a single year of quality assurance -Annual Performance Evaluations transaction data to be retrieved at a -time. This function conveniently extracts date information from the -bdate and edate parameters then makes repeated calls to the AQSAPI -retrieving a maximum of one calendar year of data at a time. Each -calendar year of data requires a separate API call so multiple years -of data will require multiple API calls. As the number of years of -data being requested increases so does the length of time that it -will take to retrieve results. There is also a 5 second wait time -inserted between successive API calls to prevent overloading the API -server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# Returns a tibble containing annual performance evaluation data - # (raw) for ozone in Baldwin County, AL for 2017 in RD format. - \dontrun{aqs_qa_annualperformanceevaltransaction_by_county(parameter = "44201", - bdate = as.Date("20170101", - format = "\%Y\%m\%d"), - edate = as.Date("20171231", - format = "\%Y\%m\%d"), - stateFIPS = "01", - countycode = "003" - ) - } -} -\seealso{ -Other Aggregate _by_site functions: -\code{\link{aqs_annualsummary_by_site}()}, -\code{\link{aqs_dailysummary_by_site}()}, -\code{\link{aqs_monitors_by_site}()}, -\code{\link{aqs_qa_annualperformanceeval_by_site}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_site}()}, -\code{\link{aqs_qa_blanks_by_site}()}, -\code{\link{aqs_qa_collocated_assessments_by_site}()}, -\code{\link{aqs_qa_flowrateaudit_by_site}()}, -\code{\link{aqs_qa_flowrateverification_by_site}()}, -\code{\link{aqs_qa_one_point_qc_by_site}()}, -\code{\link{aqs_qa_pep_audit_by_site}()}, -\code{\link{aqs_sampledata_by_site}()}, -\code{\link{aqs_services_by_site}()}, -\code{\link{aqs_transactionsample_by_site}()} -} -\concept{Aggregate _by_site functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceevaltransaction_by_pqao.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceevaltransaction_by_pqao.Rd deleted file mode 100644 index 234a58d..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceevaltransaction_by_pqao.Rd +++ /dev/null @@ -1,91 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bypqao.R -\name{aqs_qa_annualperformanceevaltransaction_by_pqao} -\alias{aqs_qa_annualperformanceevaltransaction_by_pqao} -\title{aqs_qa_annualperformanceevaltransaction_by_pqao} -\usage{ -aqs_qa_annualperformanceevaltransaction_by_pqao( - parameter, - bdate, - edate, - pqao_code, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{pqao_code}{a R character object which represents the 4 digit AQS -Primary Quality Assurance Organization code -(with leading zeroes).} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object of quality assurance -performance evaluation data. for single monitoring site for the -sitenum, countycode and stateFIPS requested for the time frame -between bdate and edate. An AQS_Data_Mart_APIv2 is a 2 item named -list in which the first item ($Header) is a tibble of header -information from the AQS API and the second item ($Data) is a -tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns AQS submissions transaction format (RD) of the annual -performance evaluation data (raw). Includes data pairs for -QA - aggregated by Primary Quality Assurance Organization (PQAO) -for a parameter code aggregated by matching input parameter and -pqao_code provided for bdate - edate time frame. -} -\note{ -The AQS API only allows for a single year of quality assurance -Annual Performance Evaluations transaction data to be retrieved at a -time. This function conveniently extracts date information from the -bdate and edate parameters then makes repeated calls to the AQSAPI -retrieving a maximum of one calendar year of data at a time. Each -calendar year of data requires a separate API call so multiple years -of data will require multiple API calls. As the number of years of -data being requested increases so does the length of time that it -will take to retrieve results. There is also a 5 second wait time -inserted between successive API calls to prevent overloading the API -server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -#Returns a tibble containing annual performance evaluation data for - # ozone in where the PQAO is the Alabama Department of - # Environmental Management (pqao_code 0013) for 2017 in RD format. - \dontrun{aqs_qa_annualperformanceevaltransaction_by_pqao(parameter = - "44201", - bdate = as.Date("20170101", - format = "\%Y\%m\%d"), - edate = as.Date("20171231", - format = "\%Y\%m\%d"), - pqao_code = "0013" - ) - } -} -\seealso{ -Other Aggregate _by_pqao functions: -\code{\link{aqs_qa_annualperformanceeval_by_pqao}()}, -\code{\link{aqs_qa_blanks_by_pqao}()}, -\code{\link{aqs_qa_collocated_assessments_by_pqao}()}, -\code{\link{aqs_qa_flowrateaudit_by_pqao}()}, -\code{\link{aqs_qa_flowrateverification_by_pqao}()}, -\code{\link{aqs_qa_one_point_qc_by_pqao}()}, -\code{\link{aqs_qa_pep_audit_by_pqao}()} -} -\concept{Aggregate _by_pqao functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceevaltransaction_by_site.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceevaltransaction_by_site.Rd deleted file mode 100644 index 100acb1..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceevaltransaction_by_site.Rd +++ /dev/null @@ -1,127 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bysite.R -\name{aqs_qa_annualperformanceevaltransaction_by_site} -\alias{aqs_qa_annualperformanceevaltransaction_by_site} -\title{aqs_qa_annualperformanceevaltransaction_by_site} -\usage{ -aqs_qa_annualperformanceevaltransaction_by_site( - parameter, - bdate, - edate, - stateFIPS, - countycode, - sitenum, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{sitenum}{a R character object which represents the 4 digit site number -(with leading zeros) within the county and state being -requested.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object of quality assurance -annual performance evaluation data in the RD format for a single -monitoring site for the sitenum, countycode and stateFIPS requested -for the time frame between bdate and edate in the AQS. An -AQS_Data_Mart_APIv2 is a 2 item named list in which the first item -($Header) is a tibble of header information from the AQS API and -the second item ($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns AQS submissions transaction format (RD) of the annual -performance evaluation data (raw). Includes data pairs for -QA - aggregated by site for a parameter code aggregated by matching -input parameter, sitenum, countycode and stateFIPS provided for -bdate - edate time frame. -} -\note{ -The AQS API only allows for a single year of quality assurance -Annual Performance Evaluations transaction data to be retrieved at a -time. This function conveniently extracts date information from the -bdate and edate parameters then makes repeated calls to the AQSAPI -retrieving a maximum of one calendar year of data at a time. Each -calendar year of data requires a separate API call so multiple years -of data will require multiple API calls. As the number of years of -data being requested increases so does the length of time that it -will take to retrieve results. There is also a 5 second wait time -inserted between successive API calls to prevent overloading the API -server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -#Returns a tibble containing annual performance evaluation data - # (raw) for ozone at the Fairhope site in Baldwin County, AL for - # 2017 in RD format. -\dontrun{aqs_qa_annualperformanceevaltransaction_by_site(parameter = "44201", - bdate = as.Date("20170101", - format = "\%Y\%m\%d"), - edate = as.Date("20171231", - format = "\%Y\%m\%d"), - stateFIPS = "01", - countycode = "003", - sitenum = "0010" - ) - } -} -\seealso{ -Other Aggregate _by_site functions: -\code{\link{aqs_annualsummary_by_site}()}, -\code{\link{aqs_dailysummary_by_site}()}, -\code{\link{aqs_monitors_by_site}()}, -\code{\link{aqs_qa_annualperformanceeval_by_site}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_county}()}, -\code{\link{aqs_qa_blanks_by_site}()}, -\code{\link{aqs_qa_collocated_assessments_by_site}()}, -\code{\link{aqs_qa_flowrateaudit_by_site}()}, -\code{\link{aqs_qa_flowrateverification_by_site}()}, -\code{\link{aqs_qa_one_point_qc_by_site}()}, -\code{\link{aqs_qa_pep_audit_by_site}()}, -\code{\link{aqs_sampledata_by_site}()}, -\code{\link{aqs_services_by_site}()}, -\code{\link{aqs_transactionsample_by_site}()} -} -\concept{Aggregate _by_site functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceevaltransaction_by_state.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceevaltransaction_by_state.Rd deleted file mode 100644 index 7fbc07c..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_annualperformanceevaltransaction_by_state.Rd +++ /dev/null @@ -1,90 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bystate.R -\name{aqs_qa_annualperformanceevaltransaction_by_state} -\alias{aqs_qa_annualperformanceevaltransaction_by_state} -\title{aqs_qa_annualperformanceevaltransaction_by_state} -\usage{ -aqs_qa_annualperformanceevaltransaction_by_state( - parameter, - bdate, - edate, - stateFIPS, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object of quality assurance -performance evaluation data. for single monitoring site for the -sitenum, countycode and stateFIPS requested for the time frame -between bdate and edate. An AQS_Data_Mart_APIv2 is a 2 item named -list in which the first item ($Header) is a tibble of header -information from the AQS API and the second item ($Data) is a -tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns AQS submissions transaction format (RD) of the annual -performance evaluation data (raw). Includes data pairs for -QA - aggregated by state for a parameter code aggregated by -matching input parameter and stateFIPS provided for bdate - edate -time frame. -} -\note{ -The AQS API only allows for a single year of quality assurance -Annual Performance Evaluations transaction data to be retrieved at a -time. This function conveniently extracts date information from the -bdate and edate parameters then makes repeated calls to the AQSAPI -retrieving a maximum of one calendar year of data at a time. Each -calendar year of data requires a separate API call so multiple years -of data will require multiple API calls. As the number of years of -data being requested increases so does the length of time that it -will take to retrieve results. There is also a 5 second wait time -inserted between successive API calls to prevent overloading the API -server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# Returns a tibble containing annual performance evaluation data - # for ozone in Alabmba for 2017 in RD format. -\dontrun{ - aqs_qa_annualperformanceevaltransaction_by_state(parameter = "44201", - bdate = as.Date("20170101", - format = "\%Y\%m\%d"), - edate = as.Date("20171231", - format = "\%Y\%m\%d") - stateFIPS = "01" - ) - } -} -\seealso{ -Other Aggregate _by_state functions: -\code{\link{aqs_qa_annualperformanceeval_by_state}()}, -\code{\link{aqs_quarterlysummary_by_box}()}, -\code{\link{aqs_quarterlysummary_by_cbsa}()}, -\code{\link{aqs_quarterlysummary_by_state}()}, -\code{\link{aqs_transactionsample_by_MA}()}, -\code{\link{aqs_transactionsample_by_state}()} -} -\concept{Aggregate _by_state functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_blanks_by_MA.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_blanks_by_MA.Rd deleted file mode 100644 index 66a936f..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_blanks_by_MA.Rd +++ /dev/null @@ -1,108 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/byma.R -\name{aqs_qa_blanks_by_MA} -\alias{aqs_qa_blanks_by_MA} -\title{aqs_qa_blanks_by_MA} -\usage{ -aqs_qa_blanks_by_MA( - parameter, - bdate, - edate, - MA_code, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be -returned.} - -\item{MA_code}{a R character object which represents the 4 digit AQS -Monitoring Agency code (with leading zeroes).} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. If TRUE -returns a AQSAPI_v2 object which is a two item list that contains header -information returned from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data_Mart_APIv2 S3 object that contains quality -assurance blank sample data for all monitors within the input -MA_code. An AQS_Data_Mart_APIv2 is a 2 item named -list in which the first item ($Header) is a tibble of header -information from the AQS API and the second item ($Data) is a -tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a table of blank quality assurance data. -Blanks are unexposed sample collection devices (e.g., -filters) that are transported with the exposed sample devices -to assess if contamination is occurring during the transport -or handling of the samples. Data is aggregated by monitoring agency -code (MA_code). -} -\note{ -The AQS API only allows for a single year of qa_blank data to be -retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\section{by_ma aggregate functions}{ -NA -} - -\examples{ -# Returns a tibble containing PM2.5 blank data in - # January 2018 where the Monitoring Agency is the Alabama - # Department of Environmental Management (agency 0013) - \dontrun{aqs_qa_blanks_by_MA(parameter = "88101", - bdate = as.Date("20170101", - format = "\%Y\%m\%d"), - edate = as.Date("20190131", - format = "\%Y\%m\%d"), - MA_code = "0013" - ) - } -} -\seealso{ -Other Aggregate _by_MA functions: -\code{\link{aqs_qa_annualperformanceeval_by_MA}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_MA}()}, -\code{\link{aqs_qa_collocated_assessments_by_MA}()}, -\code{\link{aqs_qa_flowrateaudit_by_MA}()}, -\code{\link{aqs_qa_flowrateverification_by_MA}()}, -\code{\link{aqs_qa_one_point_qc_by_MA}()}, -\code{\link{aqs_qa_pep_audit_by_MA}()} -} -\concept{Aggregate _by_MA functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_blanks_by_county.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_blanks_by_county.Rd deleted file mode 100644 index f24758d..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_blanks_by_county.Rd +++ /dev/null @@ -1,118 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bycounty.R -\name{aqs_qa_blanks_by_county} -\alias{aqs_qa_blanks_by_county} -\title{aqs_qa_blanks_by_county} -\usage{ -aqs_qa_blanks_by_county( - parameter, - bdate, - edate, - stateFIPS, - countycode, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be -returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. If -TRUE returns a AQSAPI_v2 object which is a two item -list that contains header information returned from -the API server mostly used for debugging purposes in -addition to the data requested.} -} -\value{ -a tibble or an AQS_Data_Mart_APIv2 S3 object that contains quality -assurance blank sample data for all monitors within the input -stateFIPS and countycode. An AQS_Data_Mart_APIv2 is a 2 item named -list in which the first item ($Header) is a tibble of header -information from the AQS API and the second item ($Data) is a -tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a table of blank quality assurance data. -Blanks are unexposed sample collection devices (e.g., -filters) that are transported with the exposed sample devices -to assess if contamination is occurring during the transport -or handling of the samples. Data is aggregated at the county level. -} -\note{ -The AQS API only allows for a single year of qa_blank data to be -retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# returns a tibble with PM2.5 blank data for - # Colbert County, AL for January 2018 - \dontrun{aqs_qa_blanks_by_county(parameter = "88101", - bdate = as.Date("20170101", - format="\%Y\%m\%d"), - edate = as.Date("20190131", - format="\%Y\%m\%d"), - stateFIPS = "01", - countycode = "033" - ) - } -} -\seealso{ -Other Aggregate _by_county functions: -\code{\link{aqs_annualsummary_by_county}()}, -\code{\link{aqs_dailysummary_by_county}()}, -\code{\link{aqs_monitors_by_county}()}, -\code{\link{aqs_qa_annualperformanceeval_by_county}()}, -\code{\link{aqs_qa_collocated_assessments_by_county}()}, -\code{\link{aqs_qa_flowrateaudit_by_county}()}, -\code{\link{aqs_qa_flowrateverification_by_county}()}, -\code{\link{aqs_qa_one_point_qc_by_county}()}, -\code{\link{aqs_qa_pep_audit_by_county}()}, -\code{\link{aqs_quarterlysummary_by_county}()}, -\code{\link{aqs_quarterlysummary_by_site}()}, -\code{\link{aqs_sampledata_by_county}()}, -\code{\link{aqs_transactionsample_by_county}()} -} -\concept{Aggregate _by_county functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_blanks_by_pqao.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_blanks_by_pqao.Rd deleted file mode 100644 index 52cdb02..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_blanks_by_pqao.Rd +++ /dev/null @@ -1,107 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bypqao.R -\name{aqs_qa_blanks_by_pqao} -\alias{aqs_qa_blanks_by_pqao} -\title{aqs_qa_blanks_by_pqao} -\usage{ -aqs_qa_blanks_by_pqao( - parameter, - bdate, - edate, - pqao_code, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{pqao_code}{a R character object which represents the 4 digit AQS -Primary Quality Assurance Organization code -(with leading zeroes).} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. If TRUE -returns a AQSAPI_v2 object which is a two item list that contains header -information returned from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -assurance blank data for monitors within a pqao. An -AQS_Data Mart_APIv2 is a 2 item named list in which the first item -($Header) is a tibble of header information from the AQS API and -the second item ($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a table of blank quality assurance data. -Blanks are unexposed sample collection devices (e.g., -filters) that are transported with the exposed sample devices -to assess if contamination is occurring during the transport -or handling of the samples. Data is aggregated by -Primary Quality Assurance Organization (PQAO). -} -\note{ -The AQS API only allows for a single year of flow rate audit data to -be retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\section{by_pqao aggregate functions}{ -NA -} - -\examples{ -# Returns tibble of PM2.5 blank data in - # January 2018 where the PQAO is the Alabama Department of - # Environmental Management (agency 0013) - \dontrun{aqs_qa_blanks_by_pqao(parameter = "88101", - bdate = as.Date("20180101", - format = "\%Y\%m\%d"), - edate = as.Date("20180131", - format = "\%Y\%m\%d"), - pqao_code = "0013" - ) - } -} -\seealso{ -Other Aggregate _by_pqao functions: -\code{\link{aqs_qa_annualperformanceeval_by_pqao}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_pqao}()}, -\code{\link{aqs_qa_collocated_assessments_by_pqao}()}, -\code{\link{aqs_qa_flowrateaudit_by_pqao}()}, -\code{\link{aqs_qa_flowrateverification_by_pqao}()}, -\code{\link{aqs_qa_one_point_qc_by_pqao}()}, -\code{\link{aqs_qa_pep_audit_by_pqao}()} -} -\concept{Aggregate _by_pqao functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_blanks_by_site.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_blanks_by_site.Rd deleted file mode 100644 index 9557db7..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_blanks_by_site.Rd +++ /dev/null @@ -1,127 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bysite.R -\name{aqs_qa_blanks_by_site} -\alias{aqs_qa_blanks_by_site} -\title{aqs_qa_blanks_by_site} -\usage{ -aqs_qa_blanks_by_site( - parameter, - bdate, - edate, - stateFIPS, - countycode, - sitenum, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{sitenum}{a R character object which represents the 4 digit site number -(with leading zeros) within the county and state being -requested.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data_Mart_APIv2 S3 object that contains quality -assurance blank sample data for single monitoring site for the -sitenum, countycode and stateFIPS requested for the time frame -between bdate and edate. An AQS_Data_Mart_APIv2 is a 2 item named -list in which the first item ($Header) is a tibble of header -information from the AQS API and the second item ($Data) is a -tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a table of blank quality assurance data. -Blanks are unexposed sample collection devices (e.g., -filters) that are transported with the exposed sample devices -to assess if contamination is occurring during the transport -or handling of the samples. Data is aggregated at the site level. -} -\note{ -The AQS API only allows for a single year of qa_blank data to be -retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -#Returns a tibble of PM2.5 blank - # data for the Muscle Shoals site (#0014) in Colbert County, AL - # for January 2018 - \dontrun{ - aqs_qa_blanks_by_site(parameter = "88101", - bdate = as.Date("20170101", - format="\%Y\%m\%d"), - edate = as.Date("20190131", - format="\%Y\%m\%d"), - stateFIPS = "01", - countycode = "033", - sitenum = "1002" - ) - } -} -\seealso{ -Other Aggregate _by_site functions: -\code{\link{aqs_annualsummary_by_site}()}, -\code{\link{aqs_dailysummary_by_site}()}, -\code{\link{aqs_monitors_by_site}()}, -\code{\link{aqs_qa_annualperformanceeval_by_site}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_county}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_site}()}, -\code{\link{aqs_qa_collocated_assessments_by_site}()}, -\code{\link{aqs_qa_flowrateaudit_by_site}()}, -\code{\link{aqs_qa_flowrateverification_by_site}()}, -\code{\link{aqs_qa_one_point_qc_by_site}()}, -\code{\link{aqs_qa_pep_audit_by_site}()}, -\code{\link{aqs_sampledata_by_site}()}, -\code{\link{aqs_services_by_site}()}, -\code{\link{aqs_transactionsample_by_site}()} -} -\concept{Aggregate _by_site functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_blanks_by_state.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_blanks_by_state.Rd deleted file mode 100644 index 85f828d..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_blanks_by_state.Rd +++ /dev/null @@ -1,107 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bystate.R -\name{aqs_qa_blanks_by_state} -\alias{aqs_qa_blanks_by_state} -\title{aqs_qa_blanks_by_state} -\usage{ -aqs_qa_blanks_by_state( - parameter, - bdate, - edate, - stateFIPS, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data_Mart_APIv2 S3 object that contains quality -assurance blank sample data for all monitors within the input -stateFIPS. An AQS_Data_Mart_APIv2 is a 2 item named -list in which the first item ($Header) is a tibble of header -information from the AQS API and the second item ($Data) is a -tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a table of blank quality assurance data . -Blanks are unexposed sample collection devices (e.g., -filters) that are transported with the exposed sample devices -to assess if contamination is occurring during the transport -or handling of the samples. Data is aggregated at the state level. -} -\note{ -The AQS API only allows for a single year of qa_blank data to be -retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# returns a tibble which contains PM2.5 blank data - # for Alabama for January 2018 - \dontrun{aqs_qa_blanks_by_state(parameter = "88101", - bdate = as.Date("20180101", - format = "\%Y\%m\%d" - ), - edate = as.Date("20180131", - format = "\%Y\%m\%d"), - stateFIPS = "01" - ) - } -} -\seealso{ -Other Aggregate_by_state functions: -\code{\link{aqs_annualsummary_by_state}()}, -\code{\link{aqs_dailysummary_by_state}()}, -\code{\link{aqs_monitors_by_state}()}, -\code{\link{aqs_qa_collocated_assessments_by_state}()}, -\code{\link{aqs_qa_flowrateaudit_by_state}()}, -\code{\link{aqs_qa_flowrateverification_by_state}()}, -\code{\link{aqs_qa_one_point_qc_by_state}()}, -\code{\link{aqs_qa_pep_audit_by_state}()}, -\code{\link{aqs_sampledata_by_state}()} -} -\concept{Aggregate_by_state functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_collocated_assessments_by_MA.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_collocated_assessments_by_MA.Rd deleted file mode 100644 index f2c62c3..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_collocated_assessments_by_MA.Rd +++ /dev/null @@ -1,102 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/byma.R -\name{aqs_qa_collocated_assessments_by_MA} -\alias{aqs_qa_collocated_assessments_by_MA} -\title{aqs_qa_collocated_assessments_by_MA} -\usage{ -aqs_qa_collocated_assessments_by_MA( - parameter, - bdate, - edate, - MA_code, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be -returned.} - -\item{MA_code}{a R character object which represents the 4 digit AQS -Monitoring Agency code (with leading zeroes).} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. If TRUE -returns a AQSAPI_v2 object which is a two item list that contains header -information returned from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -assurance collocated assessment data for monitors within a -monitoring agency. An AQS_Data Mart_APIv2 is a 2 item named list -in which the first item ($Header) is a tibble of header information -from the AQS API and the second item ($Data) is a tibble of the -data returned. -} -\description{ -\lifecycle{stable} -Returns a table of collocated assessment data aggregated by -matching input parameter, and monitoring agency (MA) code -provided for bdate - edate time frame. -} -\note{ -The AQS API only allows for a single year of collocated assessments -data to be retrieved at a time. This function conveniently extracts -date information from the bdate and edate parameters then makes -repeated calls to the AQSAPI retrieving a maximum of one calendar -year of data at a time. Each calendar year of data requires a -separate API call so multiple years of data will require multiple API -calls. As the number of years of data being requested increases so -does the length of time that it will take to retrieve results. There -is also a 5 second wait time inserted between successive API calls to -prevent overloading the API server. This operation has a linear run -time of /(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# Returns a tibble containing collocated assessment - # data for FRM PM2.5 January 2013 where the Monitoring Agency is - # the Alabama Department of Environmental Management - # (agency 0013) - \dontrun{aqs_qa_collocated_assessments_by_MA(parameter="88101", - bdate = as.Date("20130101", - format = "\%Y\%m\%d"), - edate = as.Date("20150131", - format="\%Y\%m\%d"), - MA_code = "0013" - ) - } -} -\seealso{ -Other Aggregate _by_MA functions: -\code{\link{aqs_qa_annualperformanceeval_by_MA}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_MA}()}, -\code{\link{aqs_qa_blanks_by_MA}()}, -\code{\link{aqs_qa_flowrateaudit_by_MA}()}, -\code{\link{aqs_qa_flowrateverification_by_MA}()}, -\code{\link{aqs_qa_one_point_qc_by_MA}()}, -\code{\link{aqs_qa_pep_audit_by_MA}()} -} -\concept{Aggregate _by_MA functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_collocated_assessments_by_county.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_collocated_assessments_by_county.Rd deleted file mode 100644 index 48556d7..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_collocated_assessments_by_county.Rd +++ /dev/null @@ -1,117 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bycounty.R -\name{aqs_qa_collocated_assessments_by_county} -\alias{aqs_qa_collocated_assessments_by_county} -\title{aqs_qa_collocated_assessments_by_county} -\usage{ -aqs_qa_collocated_assessments_by_county( - parameter, - bdate, - edate, - stateFIPS, - countycode, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be -returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. If TRUE -returns a AQSAPI_v2 object which is a two item -list that contains header information returned from -the API server mostly used for debugging purposes in -addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -assurance collocated assessment data for monitors within a county. -An AQS_Data Mart_APIv2 is a 2 item named list in which the first -item ($Header) is a tibble of header information from the AQS API -and the second item ($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a table of collocated assessment data aggregated by -matching input parameter, stateFIPS and county_code provided -for bdate - edate time frame. -} -\note{ -The AQS API only allows for a single year of collocated assessments -data to be retrieved at a time. This function conveniently extracts -date information from the bdate and edate parameters then makes -repeated calls to the AQSAPI retrieving a maximum of one calendar -year of data at a time. Each calendar year of data requires a -separate API call so multiple years of data will require multiple API -calls. As the number of years of data being requested increases so -does the length of time that it will take to retrieve results. There -is also a 5 second wait time inserted between successive API calls to -prevent overloading the API server. This operation has a linear run -time of /(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# Returns a tibble with collocated assessment data - # for FRM PM2.5 in Madison County, AL for January 2015 - \dontrun{aqs_qa_collocated_assessments_by_county(parameter = "88101", - bdate = as.Date("20150101", - format = "\%Y\%m\%d" - ), - edate = as.Date("20150131", - format = "\%Y\%m\%d" - ), - stateFIPS = "01", - countycode = "089" - ) - } -} -\seealso{ -Other Aggregate _by_county functions: -\code{\link{aqs_annualsummary_by_county}()}, -\code{\link{aqs_dailysummary_by_county}()}, -\code{\link{aqs_monitors_by_county}()}, -\code{\link{aqs_qa_annualperformanceeval_by_county}()}, -\code{\link{aqs_qa_blanks_by_county}()}, -\code{\link{aqs_qa_flowrateaudit_by_county}()}, -\code{\link{aqs_qa_flowrateverification_by_county}()}, -\code{\link{aqs_qa_one_point_qc_by_county}()}, -\code{\link{aqs_qa_pep_audit_by_county}()}, -\code{\link{aqs_quarterlysummary_by_county}()}, -\code{\link{aqs_quarterlysummary_by_site}()}, -\code{\link{aqs_sampledata_by_county}()}, -\code{\link{aqs_transactionsample_by_county}()} -} -\concept{Aggregate _by_county functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_collocated_assessments_by_pqao.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_collocated_assessments_by_pqao.Rd deleted file mode 100644 index 49e0e6b..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_collocated_assessments_by_pqao.Rd +++ /dev/null @@ -1,101 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bypqao.R -\name{aqs_qa_collocated_assessments_by_pqao} -\alias{aqs_qa_collocated_assessments_by_pqao} -\title{aqs_qa_collocated_assessments_by_pqao} -\usage{ -aqs_qa_collocated_assessments_by_pqao( - parameter, - bdate, - edate, - pqao_code, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{pqao_code}{a R character object which represents the 4 digit AQS -Primary Quality Assurance Organization code -(with leading zeroes).} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. If TRUE -returns a AQSAPI_v2 object which is a two item list that contains header -information returned from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -assurance collocated assessment data for monitors within a pqao. -An AQS_Data Mart_APIv2 is a 2 item named list in which the first -item ($Header) is a tibble of header information from the AQS API -and the second item ($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a table of collocated assessment data aggregated by -matching input parameter, and Primary Quality Assurance -Organisation (PQAO) code provided for bdate - edate -time frame. -} -\note{ -The AQS API only allows for a single year of collocated assessments -data to be retrieved at a time. This function conveniently extracts -date information from the bdate and edate parameters then makes -repeated calls to the AQSAPI retrieving a maximum of one calendar -year of data at a time. Each calendar year of data requires a -separate API call so multiple years of data will require multiple API -calls. As the number of years of data being requested increases so -does the length of time that it will take to retrieve results. There -is also a 5 second wait time inserted between successive API calls to -prevent overloading the API server. This operation has a linear run -time of /(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# Returns a tibble of collocated assessment - # data for FRM PM2.5 in January 2013 where the PQAO is the Alabama - # Department of Environmental Management (agency 0013) - \dontrun{aqs_qa_collocated_assessments_by_pqao(parameter = "88101", - bdate = as.Date("20130101", - format = "\%Y\%m\%d"), - edate = as.Date("20150131", - format = "\%Y\%m\%d"), - pqao_code = "0013" - ) - } -} -\seealso{ -Other Aggregate _by_pqao functions: -\code{\link{aqs_qa_annualperformanceeval_by_pqao}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_pqao}()}, -\code{\link{aqs_qa_blanks_by_pqao}()}, -\code{\link{aqs_qa_flowrateaudit_by_pqao}()}, -\code{\link{aqs_qa_flowrateverification_by_pqao}()}, -\code{\link{aqs_qa_one_point_qc_by_pqao}()}, -\code{\link{aqs_qa_pep_audit_by_pqao}()} -} -\concept{Aggregate _by_pqao functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_collocated_assessments_by_site.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_collocated_assessments_by_site.Rd deleted file mode 100644 index e884c02..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_collocated_assessments_by_site.Rd +++ /dev/null @@ -1,124 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bysite.R -\name{aqs_qa_collocated_assessments_by_site} -\alias{aqs_qa_collocated_assessments_by_site} -\title{aqs_qa_collocated_assessments_by_site} -\usage{ -aqs_qa_collocated_assessments_by_site( - parameter, - bdate, - edate, - stateFIPS, - countycode, - sitenum, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{sitenum}{a R character object which represents the 4 digit site number -(with leading zeros) within the county and state being -requested.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -assurance collocated assessment data for monitors within a site. -An AQS_Data Mart_APIv2 is a 2 item named list in which the first -item ($Header) is a tibble of header information from the AQS API -and the second item ($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a table of collocated assessment data aggregated by -matching input parameter, stateFIPS, county_code, and -sitenum provided for bdate - edate time frame. -} -\note{ -The AQS API only allows for a single year of collocated assessments -data to be retrieved at a time. This function conveniently extracts -date information from the bdate and edate parameters then makes -repeated calls to the AQSAPI retrieving a maximum of one calendar -year of data at a time. Each calendar year of data requires a -separate API call so multiple years of data will require multiple API -calls. As the number of years of data being requested increases so -does the length of time that it will take to retrieve results. There -is also a 5 second wait time inserted between successive API calls to -prevent overloading the API server. This operation has a linear run -time of /(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -#returns a tibble of collocated assessment data - # for FRM PM2.5 at the Huntsville Old Airport site (\#0014) - # in Madison County, AL for January 2015: - \dontrun{aqs_qa_collocated_assessments_by_site(parameter = "88101", - bdate = as.Date("20150101", - format = "\%Y\%m\%d" - ), - edate = as.Date("20150131", - format = "\%Y\%m\%d" - ), - stateFIPS = "01", - countycode = "089", - sitenum = "0014" - ) - } -} -\seealso{ -Other Aggregate _by_site functions: -\code{\link{aqs_annualsummary_by_site}()}, -\code{\link{aqs_dailysummary_by_site}()}, -\code{\link{aqs_monitors_by_site}()}, -\code{\link{aqs_qa_annualperformanceeval_by_site}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_county}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_site}()}, -\code{\link{aqs_qa_blanks_by_site}()}, -\code{\link{aqs_qa_flowrateaudit_by_site}()}, -\code{\link{aqs_qa_flowrateverification_by_site}()}, -\code{\link{aqs_qa_one_point_qc_by_site}()}, -\code{\link{aqs_qa_pep_audit_by_site}()}, -\code{\link{aqs_sampledata_by_site}()}, -\code{\link{aqs_services_by_site}()}, -\code{\link{aqs_transactionsample_by_site}()} -} -\concept{Aggregate _by_site functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_collocated_assessments_by_state.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_collocated_assessments_by_state.Rd deleted file mode 100644 index 432f241..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_collocated_assessments_by_state.Rd +++ /dev/null @@ -1,105 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bystate.R -\name{aqs_qa_collocated_assessments_by_state} -\alias{aqs_qa_collocated_assessments_by_state} -\title{aqs_qa_collocated_assessments_by_state} -\usage{ -aqs_qa_collocated_assessments_by_state( - parameter, - bdate, - edate, - stateFIPS, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -assurance collocated assessment data for monitors within a state. -An AQS_Data Mart_APIv2 is a 2 item named list in which the first -item ($Header) is a tibble of header information from the AQS API -and the second item ($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a table of collocated assessment data aggregated by -matching input parameter and stateFIPS provided for bdate - -edate time frame. -} -\note{ -The AQS API only allows for a single year of collocated assessments -data to be retrieved at a time. This function conveniently extracts -date information from the bdate and edate parameters then makes -repeated calls to the AQSAPI retrieving a maximum of one calendar -year of data at a time. Each calendar year of data requires a -separate API call so multiple years of data will require multiple API -calls. As the number of years of data being requested increases so -does the length of time that it will take to retrieve results. There -is also a 5 second wait time inserted between successive API calls to -prevent overloading the API server. This operation has a linear run -time of /(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# returns a tibble of collocated - # assessment data for FRM2.5 for January 2013 - \dontrun{aqs_qa_collocated_assessments_by_state(parameter="88101", - bdate = as.Date("20130101", - format = "\%Y\%m\%d" - ), - edate = as.Date("20150131", - format = "\%Y\%m\%d" - ), - stateFIPS = "01" - ) - } -} -\seealso{ -Other Aggregate_by_state functions: -\code{\link{aqs_annualsummary_by_state}()}, -\code{\link{aqs_dailysummary_by_state}()}, -\code{\link{aqs_monitors_by_state}()}, -\code{\link{aqs_qa_blanks_by_state}()}, -\code{\link{aqs_qa_flowrateaudit_by_state}()}, -\code{\link{aqs_qa_flowrateverification_by_state}()}, -\code{\link{aqs_qa_one_point_qc_by_state}()}, -\code{\link{aqs_qa_pep_audit_by_state}()}, -\code{\link{aqs_sampledata_by_state}()} -} -\concept{Aggregate_by_state functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateaudit_by_MA.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateaudit_by_MA.Rd deleted file mode 100644 index 1929580..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateaudit_by_MA.Rd +++ /dev/null @@ -1,101 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/byma.R -\name{aqs_qa_flowrateaudit_by_MA} -\alias{aqs_qa_flowrateaudit_by_MA} -\title{aqs_qa_flowrateaudit_by_MA} -\usage{ -aqs_qa_flowrateaudit_by_MA( - parameter, - bdate, - edate, - MA_code, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be -returned.} - -\item{MA_code}{a R character object which represents the 4 digit AQS -Monitoring Agency code (with leading zeroes).} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. If TRUE -returns a AQSAPI_v2 object which is a two item list that contains header -information returned from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing flow rate -audit data for the requested MA_code. An -AQS_Data_Mart_APIv2 object is a 2 item named list in which the -first item ($Header) is a tibble of header information from the -AQS API and the second item ($Data) is a tibble of the data -returned. -} -\description{ -\lifecycle{stable} -Returns a table containing flow rate audit -data aggregated by parameter code and monitoring agency code -(_by_MA) for bdate - edate time frame. -} -\note{ -The AQS API only allows for a single year of flow rate audit data to -be retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ - # returns a tibble of flow rate audit data - # for FRM PM2.5 January 2016 - Januray 2018 where the Monitoring Agency is - # the Jefferson County, AL Department of Health (agency 0550) - \dontrun{aqs_qa_flowrateaudit_by_MA(parameter = "88101", - bdate = as.Date("20160101", - format = "\%Y\%m\%d"), - edate = as.Date("20180131", - format = "\%Y\%m\%d"), - MA_code = "0550" - ) - } -} -\seealso{ -Other Aggregate _by_MA functions: -\code{\link{aqs_qa_annualperformanceeval_by_MA}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_MA}()}, -\code{\link{aqs_qa_blanks_by_MA}()}, -\code{\link{aqs_qa_collocated_assessments_by_MA}()}, -\code{\link{aqs_qa_flowrateverification_by_MA}()}, -\code{\link{aqs_qa_one_point_qc_by_MA}()}, -\code{\link{aqs_qa_pep_audit_by_MA}()} -} -\concept{Aggregate _by_MA functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateaudit_by_county.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateaudit_by_county.Rd deleted file mode 100644 index b03d00d..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateaudit_by_county.Rd +++ /dev/null @@ -1,116 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bycounty.R -\name{aqs_qa_flowrateaudit_by_county} -\alias{aqs_qa_flowrateaudit_by_county} -\title{aqs_qa_flowrateaudit_by_county} -\usage{ -aqs_qa_flowrateaudit_by_county( - parameter, - bdate, - edate, - stateFIPS, - countycode, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be -returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing flow rate -audit data for the requested countycode and stateFIPS. An -AQS_Data_Mart_APIv2 object is a 2 item named list in which the -first item ($Header) is a tibble of header information from the -AQS API and the second item ($Data) is a tibble of the data -returned. -} -\description{ -\lifecycle{stable} -Returns a table containing flow rate audit -data aggregated by parameter code, stateFIPS and countycode -for bdate - edate time frame. -} -\note{ -The AQS API only allows for a single year of flow rate audit data to -be retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -#Returns a tibble of flow rate audit data for - # Jefferson County, AL for January 2018 - \dontrun{aqs_qa_flowrateaudit_by_county(parameter = "88101", - bdate = as.Date("20170101", - format="\%Y\%m\%d"), - edate = as.Date("20190131", - format = "\%Y\%m\%d"), - tateFIPS = "01", - countycode = "073" - ) - } -} -\seealso{ -Other Aggregate _by_county functions: -\code{\link{aqs_annualsummary_by_county}()}, -\code{\link{aqs_dailysummary_by_county}()}, -\code{\link{aqs_monitors_by_county}()}, -\code{\link{aqs_qa_annualperformanceeval_by_county}()}, -\code{\link{aqs_qa_blanks_by_county}()}, -\code{\link{aqs_qa_collocated_assessments_by_county}()}, -\code{\link{aqs_qa_flowrateverification_by_county}()}, -\code{\link{aqs_qa_one_point_qc_by_county}()}, -\code{\link{aqs_qa_pep_audit_by_county}()}, -\code{\link{aqs_quarterlysummary_by_county}()}, -\code{\link{aqs_quarterlysummary_by_site}()}, -\code{\link{aqs_sampledata_by_county}()}, -\code{\link{aqs_transactionsample_by_county}()} -} -\concept{Aggregate _by_county functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateaudit_by_pqao.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateaudit_by_pqao.Rd deleted file mode 100644 index 9d00186..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateaudit_by_pqao.Rd +++ /dev/null @@ -1,102 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bypqao.R -\name{aqs_qa_flowrateaudit_by_pqao} -\alias{aqs_qa_flowrateaudit_by_pqao} -\title{aqs_qa_flowrateaudit_by_pqao} -\usage{ -aqs_qa_flowrateaudit_by_pqao( - parameter, - bdate, - edate, - pqao_code, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{pqao_code}{a R character object which represents the 4 digit AQS -Primary Quality Assurance Organization code -(with leading zeroes).} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. If TRUE -returns a AQSAPI_v2 object which is a two item list that contains header -information returned from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing flow rate -audit data for the requested pqao_code. An -AQS_Data_Mart_APIv2 object is a 2 item named list in which the -first item ($Header) is a tibble of header information from the -AQS API and the second item ($Data) is a tibble of the data -returned. -} -\description{ -\lifecycle{stable} -Returns a table containing flow rate audit -data aggregated by parameter code and Primary Quality -Assurance Organization (PQAO) code for bdate - edate -time frame. -} -\note{ -The AQS API only allows for a single year of flow rate audit data to -be retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# Returns a tibble of flow rate audit data for January - # 2018 where the PQAO is the Jefferson County, AL Department of - # Health (agency 0550). - \dontrun{aqs_qa_flowrateaudit_by_pqao(parameter = "88101", - bdate = as.Date("20170101", - format = "\%Y\%m\%d"), - edate = as.Date("20180131", - format = "\%Y\%m\%d"), - pqao_code = "0550" - ) - } -} -\seealso{ -Other Aggregate _by_pqao functions: -\code{\link{aqs_qa_annualperformanceeval_by_pqao}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_pqao}()}, -\code{\link{aqs_qa_blanks_by_pqao}()}, -\code{\link{aqs_qa_collocated_assessments_by_pqao}()}, -\code{\link{aqs_qa_flowrateverification_by_pqao}()}, -\code{\link{aqs_qa_one_point_qc_by_pqao}()}, -\code{\link{aqs_qa_pep_audit_by_pqao}()} -} -\concept{Aggregate _by_pqao functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateaudit_by_site.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateaudit_by_site.Rd deleted file mode 100644 index 4a6de8f..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateaudit_by_site.Rd +++ /dev/null @@ -1,123 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bysite.R -\name{aqs_qa_flowrateaudit_by_site} -\alias{aqs_qa_flowrateaudit_by_site} -\title{aqs_qa_flowrate audit_by_site} -\usage{ -aqs_qa_flowrateaudit_by_site( - parameter, - bdate, - edate, - stateFIPS, - countycode, - sitenum, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{sitenum}{a R character object which represents the 4 digit site number -(with leading zeros) within the county and state being -requested.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing flow rate -audit data for the requested sitenum, countycode and stateFIPS. An -AQS_Data_Mart_APIv2 object is a 2 item named list in which the -first item ($Header) is a tibble of header information from the -AQS API and the second item ($Data) is a tibble of the data -returned. -} -\description{ -\lifecycle{stable} -Returns a table containing flow rate audit -data aggregated by parameter code, stateFIPS, countycode and -site number for bdate - edate time frame. -} -\note{ -The AQS API only allows for a single year of flow rate audit data to -be retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# returns a tibble of flow rate audit data - # for the Wylam site (#2003) in Jefferson County, AL - # for January 2018: - \dontrun{aqs_qa_flowrateaudit_by_site(parameter = "88101", - bdate = as.Date("20150101", - format="\%Y\%m\%d"), - edate = as.Date("20180131", - format="\%Y\%m\%d"), - stateFIPS = "01", - countycode = "073", - sitenum = "2003" - ) - } -} -\seealso{ -Other Aggregate _by_site functions: -\code{\link{aqs_annualsummary_by_site}()}, -\code{\link{aqs_dailysummary_by_site}()}, -\code{\link{aqs_monitors_by_site}()}, -\code{\link{aqs_qa_annualperformanceeval_by_site}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_county}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_site}()}, -\code{\link{aqs_qa_blanks_by_site}()}, -\code{\link{aqs_qa_collocated_assessments_by_site}()}, -\code{\link{aqs_qa_flowrateverification_by_site}()}, -\code{\link{aqs_qa_one_point_qc_by_site}()}, -\code{\link{aqs_qa_pep_audit_by_site}()}, -\code{\link{aqs_sampledata_by_site}()}, -\code{\link{aqs_services_by_site}()}, -\code{\link{aqs_transactionsample_by_site}()} -} -\concept{Aggregate _by_site functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateaudit_by_state.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateaudit_by_state.Rd deleted file mode 100644 index 6bc929a..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateaudit_by_state.Rd +++ /dev/null @@ -1,104 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bystate.R -\name{aqs_qa_flowrateaudit_by_state} -\alias{aqs_qa_flowrateaudit_by_state} -\title{aqs_qa_flowrateaudit_by_state} -\usage{ -aqs_qa_flowrateaudit_by_state( - parameter, - bdate, - edate, - stateFIPS, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two item -list that contains header information returned from -the API server mostly used for debugging purposes in -addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing flow rate -audit data for the requested stateFIPS. An -AQS_Data_Mart_APIv2 object is a 2 item named list in which the -first item ($Header) is a tibble of header information from the -AQS API and the second item ($Data) is a tibble of the data -returned. -} -\description{ -\lifecycle{stable} -Returns a table containing flow rate audit -data aggregated by parameter code and stateFIPS for -bdate - edate time frame. -} -\note{ -The AQS API only allows for a single year of flow rate audit data to -be retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# returns a tibble of flow rate audit - # data for Alabama in January 2018 - \dontrun{aqs_qa_flowrateaudit_by_state(parameter = "88101", - bdate = as.Date("20170101", - format = "\%Y\%m\%d"), - edate = as.Date("20180131", - format = "\%Y\%m\%d"), - stateFIPS = "01" - ) - } -} -\seealso{ -Other Aggregate_by_state functions: -\code{\link{aqs_annualsummary_by_state}()}, -\code{\link{aqs_dailysummary_by_state}()}, -\code{\link{aqs_monitors_by_state}()}, -\code{\link{aqs_qa_blanks_by_state}()}, -\code{\link{aqs_qa_collocated_assessments_by_state}()}, -\code{\link{aqs_qa_flowrateverification_by_state}()}, -\code{\link{aqs_qa_one_point_qc_by_state}()}, -\code{\link{aqs_qa_pep_audit_by_state}()}, -\code{\link{aqs_sampledata_by_state}()} -} -\concept{Aggregate_by_state functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateverification_by_MA.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateverification_by_MA.Rd deleted file mode 100644 index 6693f1e..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateverification_by_MA.Rd +++ /dev/null @@ -1,104 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/byma.R -\name{aqs_qa_flowrateverification_by_MA} -\alias{aqs_qa_flowrateverification_by_MA} -\title{aqs_qa_flowrateverification_by_MA} -\usage{ -aqs_qa_flowrateverification_by_MA( - parameter, - bdate, - edate, - MA_code, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be -returned.} - -\item{MA_code}{a R character object which represents the 4 digit AQS -Monitoring Agency code (with leading zeroes).} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. If TRUE -returns a AQSAPI_v2 object which is a two item list that contains header -information returned from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -assurance flow rate verification data for monitors within a -Monitoring agency. An AQS_Data Mart_APIv2 is a 2 item named list in -which the first item ($Header) is a tibble of header information -from the AQS API and the second item ($Data) is a tibble of the -data returned. -} -\description{ -\lifecycle{stable} -Returns a table containing flow rate Verification data for a -parameter code aggregated by matching input parameter, and -monitoring agency (MA) code provided for bdate - edate time -frame. -} -\note{ -The AQS API only allows for a single year of flow rate verifications to -be retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ - # Returns a tibble containing collocated assessment - # data for FRM PM2.5 January 2013 where the Monitoring Agency is - # the Alabama Department of Environmental Management (agency 0013) - \dontrun{aqs_qa_flowrateverification_by_MA(parameter = "88101", - bdate = as.Date("20130101", - format = "\%Y\%m\%d" - ), - edate = as.Date("20150131", - format = "\%Y\%m\%d" - ), - MA_code = "0013" - ) - } -} -\seealso{ -Other Aggregate _by_MA functions: -\code{\link{aqs_qa_annualperformanceeval_by_MA}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_MA}()}, -\code{\link{aqs_qa_blanks_by_MA}()}, -\code{\link{aqs_qa_collocated_assessments_by_MA}()}, -\code{\link{aqs_qa_flowrateaudit_by_MA}()}, -\code{\link{aqs_qa_one_point_qc_by_MA}()}, -\code{\link{aqs_qa_pep_audit_by_MA}()} -} -\concept{Aggregate _by_MA functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateverification_by_county.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateverification_by_county.Rd deleted file mode 100644 index 066a554..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateverification_by_county.Rd +++ /dev/null @@ -1,117 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bycounty.R -\name{aqs_qa_flowrateverification_by_county} -\alias{aqs_qa_flowrateverification_by_county} -\title{aqs_qa_flowrateverification_by_county} -\usage{ -aqs_qa_flowrateverification_by_county( - parameter, - bdate, - edate, - stateFIPS, - countycode, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be -returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -assurance flow rate verification data for monitors within a county. -An AQS_Data Mart_APIv2 is a 2 item named list in which the first -item ($Header) is a tibble of header information from the AQS API -and the second item ($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a table containing flow rate Verification data for a -parameter code aggregated matching input parameter, stateFIPS, -and county_code, provided for bdate - edate time frame. -} -\note{ -The AQS API only allows for a single year of flow rate verifications to -be retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# returns a tibble of flow rate verification data for - # Colbert County, AL for January 2018 - \dontrun{aqs_qa_flowrateverification_by_county(parameter = "88101", - bdate = as.Date("20180101", - format = "\%Y\%m\%d" - ), - edate = as.Date("20190131", - format = "\%Y\%m\%d" - ), - stateFIPS = "01", - countycode = "033" - ) - } -} -\seealso{ -Other Aggregate _by_county functions: -\code{\link{aqs_annualsummary_by_county}()}, -\code{\link{aqs_dailysummary_by_county}()}, -\code{\link{aqs_monitors_by_county}()}, -\code{\link{aqs_qa_annualperformanceeval_by_county}()}, -\code{\link{aqs_qa_blanks_by_county}()}, -\code{\link{aqs_qa_collocated_assessments_by_county}()}, -\code{\link{aqs_qa_flowrateaudit_by_county}()}, -\code{\link{aqs_qa_one_point_qc_by_county}()}, -\code{\link{aqs_qa_pep_audit_by_county}()}, -\code{\link{aqs_quarterlysummary_by_county}()}, -\code{\link{aqs_quarterlysummary_by_site}()}, -\code{\link{aqs_sampledata_by_county}()}, -\code{\link{aqs_transactionsample_by_county}()} -} -\concept{Aggregate _by_county functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateverification_by_pqao.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateverification_by_pqao.Rd deleted file mode 100644 index 4479d42..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateverification_by_pqao.Rd +++ /dev/null @@ -1,103 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bypqao.R -\name{aqs_qa_flowrateverification_by_pqao} -\alias{aqs_qa_flowrateverification_by_pqao} -\title{aqs_qa_flowrateverification_by_pqao} -\usage{ -aqs_qa_flowrateverification_by_pqao( - parameter, - bdate, - edate, - pqao_code, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{pqao_code}{a R character object which represents the 4 digit AQS -Primary Quality Assurance Organization code -(with leading zeroes).} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. If TRUE -returns a AQSAPI_v2 object which is a two item list that contains header -information returned from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -assurance flow rate verification data for monitors within a pqao. -An AQS_Data Mart_APIv2 is a 2 item named list in which the first -item ($Header) is a tibble of header information from the AQS API -and the second item ($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a table containing flow rate Verification data for a -parameter code aggregated by matching input parameter, and -Primary Quality Assurance Organization (PQAO) code provided -for bdate - edate time. -} -\note{ -The AQS API only allows for a single year of flow rate verifications to -be retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# returns a tibble of flow rate verification - # data for January 2018 where the PQAO is the Alabama Department - # of Environmental Management (agency 0013) - \dontrun{aqs_qa_flowrateverification_by_pqao(parameter = "88101", - bdate = as.Date("20170101", - format = "\%Y\%m\%d" - ), - edate = as.Date("20190131", - format = "\%Y\%m\%d" - ), - pqao_code = "0013" - ) - } -} -\seealso{ -Other Aggregate _by_pqao functions: -\code{\link{aqs_qa_annualperformanceeval_by_pqao}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_pqao}()}, -\code{\link{aqs_qa_blanks_by_pqao}()}, -\code{\link{aqs_qa_collocated_assessments_by_pqao}()}, -\code{\link{aqs_qa_flowrateaudit_by_pqao}()}, -\code{\link{aqs_qa_one_point_qc_by_pqao}()}, -\code{\link{aqs_qa_pep_audit_by_pqao}()} -} -\concept{Aggregate _by_pqao functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateverification_by_site.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateverification_by_site.Rd deleted file mode 100644 index 62d3528..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateverification_by_site.Rd +++ /dev/null @@ -1,123 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bysite.R -\name{aqs_qa_flowrateverification_by_site} -\alias{aqs_qa_flowrateverification_by_site} -\title{aqs_qa_flowrateverification_by_site} -\usage{ -aqs_qa_flowrateverification_by_site( - parameter, - bdate, - edate, - stateFIPS, - countycode, - sitenum, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{sitenum}{a R character object which represents the 4 digit site number -(with leading zeros) within the county and state being -requested.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -assurance flow rate verification data for monitors at a site. -An AQS_Data Mart_APIv2 is a 2 item named list in which the first -item ($Header) is a tibble of header information from the AQS API -and the second item ($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a table containing flow rate Verification data for a -parameter code aggregated matching input parameter, stateFIPS, -county_code, and sitenum provided for -bdate - edate time frame. -} -\note{ -The AQS API only allows for a single year of flow rate verifications to -be retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# returns a tibble of flow rate verification - # data for the Muscle Shoals site (#1002) in Colbert County, AL - # for January 2018: - \dontrun{aqs_qa_flowrateverification_by_site(parameter = "88101", - bdate = as.Date("20170101", - format = "\%Y\%m\%d"), - edate = as.Date("20180131", - format = "\%Y\%m\%d"), - stateFIPS = "01", - countycode = "033", - sitenum = "1002" - ) - } -} -\seealso{ -Other Aggregate _by_site functions: -\code{\link{aqs_annualsummary_by_site}()}, -\code{\link{aqs_dailysummary_by_site}()}, -\code{\link{aqs_monitors_by_site}()}, -\code{\link{aqs_qa_annualperformanceeval_by_site}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_county}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_site}()}, -\code{\link{aqs_qa_blanks_by_site}()}, -\code{\link{aqs_qa_collocated_assessments_by_site}()}, -\code{\link{aqs_qa_flowrateaudit_by_site}()}, -\code{\link{aqs_qa_one_point_qc_by_site}()}, -\code{\link{aqs_qa_pep_audit_by_site}()}, -\code{\link{aqs_sampledata_by_site}()}, -\code{\link{aqs_services_by_site}()}, -\code{\link{aqs_transactionsample_by_site}()} -} -\concept{Aggregate _by_site functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateverification_by_state.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateverification_by_state.Rd deleted file mode 100644 index a119746..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_flowrateverification_by_state.Rd +++ /dev/null @@ -1,105 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bystate.R -\name{aqs_qa_flowrateverification_by_state} -\alias{aqs_qa_flowrateverification_by_state} -\title{aqs_qa_flowrateverification_by_state} -\usage{ -aqs_qa_flowrateverification_by_state( - parameter, - bdate, - edate, - stateFIPS, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -assurance flow rate verification data for monitors within a state. -An AQS_Data Mart_APIv2 is a 2 item named list in which the first -item ($Header) is a tibble of header information from the AQS API -and the second item ($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a table containing flow rate Verification data for a -parameter code aggregated matching input parameter, and -stateFIPS, provided for bdate - edate time frame. -} -\note{ -The AQS API only allows for a single year of flow rate verifications to -be retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# Returns a tibble of flow rate verification data for the state of - # Alabama for 2017-2019 - \dontrun{aqs_qa_flowrateverification_by_state(parameter = "88101", - bdate = as.Date("20170101", - format = "\%Y\%m\%d" - ), - edate = as.Date("20190131", - format="\%Y\%m\%d" - ), - stateFIPS = "01" - ) - } -} -\seealso{ -Other Aggregate_by_state functions: -\code{\link{aqs_annualsummary_by_state}()}, -\code{\link{aqs_dailysummary_by_state}()}, -\code{\link{aqs_monitors_by_state}()}, -\code{\link{aqs_qa_blanks_by_state}()}, -\code{\link{aqs_qa_collocated_assessments_by_state}()}, -\code{\link{aqs_qa_flowrateaudit_by_state}()}, -\code{\link{aqs_qa_one_point_qc_by_state}()}, -\code{\link{aqs_qa_pep_audit_by_state}()}, -\code{\link{aqs_sampledata_by_state}()} -} -\concept{Aggregate_by_state functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_one_point_qc_by_MA.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_one_point_qc_by_MA.Rd deleted file mode 100644 index db7f789..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_one_point_qc_by_MA.Rd +++ /dev/null @@ -1,101 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/byma.R -\name{aqs_qa_one_point_qc_by_MA} -\alias{aqs_qa_one_point_qc_by_MA} -\title{aqs_qa_one_point_qc_by_MA} -\usage{ -aqs_qa_one_point_qc_by_MA( - parameter, - bdate, - edate, - MA_code, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be -returned.} - -\item{MA_code}{a R character object which represents the 4 digit AQS -Monitoring Agency code (with leading zeroes).} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. If TRUE -returns a AQSAPI_v2 object which is a two item list that contains header -information returned from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing one point -qc data for a single monitoring agency. A AQS_Data_Mart_APIv2 -object is a 2 item named list in which the first item ($Header) -is a tibble of header information from the AQS API and the second -item ($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a tibble or an AQS_Data Mart_APIv2 S3 object -containing one point QC check data aggregated by monitoring -agency code (_by_MA). -} -\note{ -The AQS API only allows for a single year of one point qc data to -be retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# returns a tibble of ozone One Point QC data - # in January 2018 where the Monitoring Agency is the - # Massachusetts Department of Environmental Protection - # (agency 0660) - \dontrun{aqs_qa_one_point_qc_by_MA(parameter = "44201", - bdate = as.Date("20170101", - format = "\%Y\%m\%d"), - edate = as.Date("20180131", - format = "\%Y\%m\%d"), - MA_code = "0660" - ) - } -} -\seealso{ -Other Aggregate _by_MA functions: -\code{\link{aqs_qa_annualperformanceeval_by_MA}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_MA}()}, -\code{\link{aqs_qa_blanks_by_MA}()}, -\code{\link{aqs_qa_collocated_assessments_by_MA}()}, -\code{\link{aqs_qa_flowrateaudit_by_MA}()}, -\code{\link{aqs_qa_flowrateverification_by_MA}()}, -\code{\link{aqs_qa_pep_audit_by_MA}()} -} -\concept{Aggregate _by_MA functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_one_point_qc_by_county.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_one_point_qc_by_county.Rd deleted file mode 100644 index 888f012..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_one_point_qc_by_county.Rd +++ /dev/null @@ -1,114 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bycounty.R -\name{aqs_qa_one_point_qc_by_county} -\alias{aqs_qa_one_point_qc_by_county} -\title{aqs_qa_one_point_qc_by_county_} -\usage{ -aqs_qa_one_point_qc_by_county( - parameter, - bdate, - edate, - stateFIPS, - countycode, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be -returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. If TRUE -returns a AQSAPI_v2 object which is a two item -list that contains header information returned from -the API server mostly used for debugging purposes in -addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing one point -qc data within a county. A AQS_Data_Mart_APIv2 object is a -2 item named list in which the first item ($Header) is a tibble -of header information from the AQS API and the second item -($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a tibble or an AQS_Data Mart_APIv2 S3 object -containing one point QC check data aggregated by county_code. -} -\note{ -The AQS API only allows for a single year of one point qc data to -be retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -#returns a tibble of One Point QC data for ozone - # in Barnstable County, MA for January 2018 - \dontrun{aqs_qa_one_point_qc_by_county(parameter= "44201", - bdate = as.Date("20170101", - format = "\%Y\%m\%d"), - edate = a s.Date("20180131", - format = "\%Y\%m\%d"), - stateFIPS = "25", - countycode = "001" - ) - } -} -\seealso{ -Other Aggregate _by_county functions: -\code{\link{aqs_annualsummary_by_county}()}, -\code{\link{aqs_dailysummary_by_county}()}, -\code{\link{aqs_monitors_by_county}()}, -\code{\link{aqs_qa_annualperformanceeval_by_county}()}, -\code{\link{aqs_qa_blanks_by_county}()}, -\code{\link{aqs_qa_collocated_assessments_by_county}()}, -\code{\link{aqs_qa_flowrateaudit_by_county}()}, -\code{\link{aqs_qa_flowrateverification_by_county}()}, -\code{\link{aqs_qa_pep_audit_by_county}()}, -\code{\link{aqs_quarterlysummary_by_county}()}, -\code{\link{aqs_quarterlysummary_by_site}()}, -\code{\link{aqs_sampledata_by_county}()}, -\code{\link{aqs_transactionsample_by_county}()} -} -\concept{Aggregate _by_county functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_one_point_qc_by_pqao.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_one_point_qc_by_pqao.Rd deleted file mode 100644 index 5320a90..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_one_point_qc_by_pqao.Rd +++ /dev/null @@ -1,99 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bypqao.R -\name{aqs_qa_one_point_qc_by_pqao} -\alias{aqs_qa_one_point_qc_by_pqao} -\title{aqs_qa_one_point_qc_by_pqao} -\usage{ -aqs_qa_one_point_qc_by_pqao( - parameter, - bdate, - edate, - pqao_code, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{pqao_code}{a R character object which represents the 4 digit AQS -Primary Quality Assurance Organization code -(with leading zeroes).} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. If TRUE -returns a AQSAPI_v2 object which is a two item list that contains header -information returned from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing one point -qc data within a pqao. A AQS_Data_Mart_APIv2 object is a -2 item named list in which the first item ($Header) is a tibble -of header information from the AQS API and the second item -} -\description{ -\lifecycle{stable} -Returns a tibble or an AQS_Data Mart_APIv2 S3 object containing Quality -assurance data - collocated assessment raw data aggregated by Primary -Quality Assurance Organization (PQAO) code. -} -\note{ -The AQS API only allows for a single year of one point qc data to -be retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ - # returns a tibble of ozone One Point QC - # data for Jan 2017 - January 2018 where the PQAO is the Massachusetts - # Department of Environmental Protection (agency 0660) - \dontrun{aqs_qa_one_point_qc_by_pqao(parameter = "88101", - bdate = as.Date("20170101", - format = "\%Y\%m\%d"), - edate = as.Date("20180131", - format = "\%Y\%m\%d"), - pqao_code = "0660" - ) - } -} -\seealso{ -Other Aggregate _by_pqao functions: -\code{\link{aqs_qa_annualperformanceeval_by_pqao}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_pqao}()}, -\code{\link{aqs_qa_blanks_by_pqao}()}, -\code{\link{aqs_qa_collocated_assessments_by_pqao}()}, -\code{\link{aqs_qa_flowrateaudit_by_pqao}()}, -\code{\link{aqs_qa_flowrateverification_by_pqao}()}, -\code{\link{aqs_qa_pep_audit_by_pqao}()} -} -\concept{Aggregate _by_pqao functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_one_point_qc_by_site.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_one_point_qc_by_site.Rd deleted file mode 100644 index c0b0b09..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_one_point_qc_by_site.Rd +++ /dev/null @@ -1,122 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bysite.R -\name{aqs_qa_one_point_qc_by_site} -\alias{aqs_qa_one_point_qc_by_site} -\title{aqs_qa_one_point_qc_by_site} -\usage{ -aqs_qa_one_point_qc_by_site( - parameter, - bdate, - edate, - stateFIPS, - countycode, - sitenum, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{sitenum}{a R character object which represents the 4 digit site number -(with leading zeros) within the county and state being -requested.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing one point -qc data for the requested site. A AQS_Data_Mart_APIv2 object is a -2 item named list in which the first item ($Header) is a tibble -of header information from the AQS API and the second item -($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a table of one point QC raw data -aggregated by parameter code, stateFIPS, countycode and -site number. -} -\note{ -The AQS API only allows for a single year of one point qc data to -be retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# returns a tibbble of One Point QC data for - # ozone at the Truro National Seashore site (\#0002) in - # Barnstable County, MA for January 2018: - \dontrun{aqs_qa_one_point_qc_by_site(parameter = "44201", - bdate = as.Date("20180101", - format = "\%Y\%m\%d"), - edate = as.Date("20180131", - format = "\%Y\%m\%d"), - stateFIPS = "25", - countycode = "001", - sitenum = "0002" - ) - } -} -\seealso{ -Other Aggregate _by_site functions: -\code{\link{aqs_annualsummary_by_site}()}, -\code{\link{aqs_dailysummary_by_site}()}, -\code{\link{aqs_monitors_by_site}()}, -\code{\link{aqs_qa_annualperformanceeval_by_site}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_county}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_site}()}, -\code{\link{aqs_qa_blanks_by_site}()}, -\code{\link{aqs_qa_collocated_assessments_by_site}()}, -\code{\link{aqs_qa_flowrateaudit_by_site}()}, -\code{\link{aqs_qa_flowrateverification_by_site}()}, -\code{\link{aqs_qa_pep_audit_by_site}()}, -\code{\link{aqs_sampledata_by_site}()}, -\code{\link{aqs_services_by_site}()}, -\code{\link{aqs_transactionsample_by_site}()} -} -\concept{Aggregate _by_site functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_one_point_qc_by_state.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_one_point_qc_by_state.Rd deleted file mode 100644 index d1b959c..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_one_point_qc_by_state.Rd +++ /dev/null @@ -1,105 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bystate.R -\name{aqs_qa_one_point_qc_by_state} -\alias{aqs_qa_one_point_qc_by_state} -\title{aqs_qa_one_point_qc_by_state} -\usage{ -aqs_qa_one_point_qc_by_state( - parameter, - bdate, - edate, - stateFIPS, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. If TRUE -returns a AQSAPI_v2 object which is a two item -list that contains header information returned from -the API server mostly used for debugging purposes in -addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing one point -qc data within a state. A AQS_Data_Mart_APIv2 object is a -2 item named list in which the first item ($Header) is a tibble -of header information from the AQS API and the second item -($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a tibble or an AQS_Data Mart_APIv2 S3 -object containing Quality assurance data - flow rate audit -raw data aggregated by state FIPS. -} -\note{ -The AQS API only allows for a single year of one point qc data to -be retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# returns a tibble of one point QC check - # data for ozone in Massachusettes in January 2018 - \dontrun{aqs_qa_one_point_qc_by_state(parameter = "44201", - bdate = as.Date("20170101", - format = "\%Y\%m\%d" - ), - edate = as.Date("20190131", - format = "\%Y\%m\%d" - ), - stateFIPS = "25" - ) - } -} -\seealso{ -Other Aggregate_by_state functions: -\code{\link{aqs_annualsummary_by_state}()}, -\code{\link{aqs_dailysummary_by_state}()}, -\code{\link{aqs_monitors_by_state}()}, -\code{\link{aqs_qa_blanks_by_state}()}, -\code{\link{aqs_qa_collocated_assessments_by_state}()}, -\code{\link{aqs_qa_flowrateaudit_by_state}()}, -\code{\link{aqs_qa_flowrateverification_by_state}()}, -\code{\link{aqs_qa_pep_audit_by_state}()}, -\code{\link{aqs_sampledata_by_state}()} -} -\concept{Aggregate_by_state functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_pep_audit_by_MA.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_pep_audit_by_MA.Rd deleted file mode 100644 index fa26b29..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_pep_audit_by_MA.Rd +++ /dev/null @@ -1,101 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/byma.R -\name{aqs_qa_pep_audit_by_MA} -\alias{aqs_qa_pep_audit_by_MA} -\title{aqs_qa_pep_audit_by_MA} -\usage{ -aqs_qa_pep_audit_by_MA( - parameter, - bdate, - edate, - MA_code, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be -returned.} - -\item{MA_code}{a R character object which represents the 4 digit AQS -Monitoring Agency code (with leading zeroes).} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. If TRUE -returns a AQSAPI_v2 object which is a two item list that contains header -information returned from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -assurance PEP audit data for a monitoring agency. A -AQS_Data_Mart_APIv2 object is a 2 item named list in which the -first item ($Header) is a tibble of header information from the -AQS API and the second item ($Data) is a tibble of the data -returned. -} -\description{ -\lifecycle{stable} -Returns a table of Performance Evaluation Program (PEP) audit -data aggregated by monitoring agency code (_by_MA) for the -time frame between bdate and edate. -} -\note{ -The AQS API only allows for a single year of one point pep audit data -to be retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# Returns a tibble of PEP audit data for - # June 2017 where the Monitoring Agency is the Alabama Department - # of Environmental Management (agency 0013) - \dontrun{aqs_qa_pep_audit_by_MA(parameter = "88101", - bdate = as.Date("20170601", - format = "\%Y\%m\%d"), - edate = as.Date("20170630", - format = "\%Y\%m\%d"), - MA_code = "0013" - ) - } -} -\seealso{ -Other Aggregate _by_MA functions: -\code{\link{aqs_qa_annualperformanceeval_by_MA}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_MA}()}, -\code{\link{aqs_qa_blanks_by_MA}()}, -\code{\link{aqs_qa_collocated_assessments_by_MA}()}, -\code{\link{aqs_qa_flowrateaudit_by_MA}()}, -\code{\link{aqs_qa_flowrateverification_by_MA}()}, -\code{\link{aqs_qa_one_point_qc_by_MA}()} -} -\concept{Aggregate _by_MA functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_pep_audit_by_county.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_pep_audit_by_county.Rd deleted file mode 100644 index 920b1f0..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_pep_audit_by_county.Rd +++ /dev/null @@ -1,117 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bycounty.R -\name{aqs_qa_pep_audit_by_county} -\alias{aqs_qa_pep_audit_by_county} -\title{aqs_qa_pep_audit_by_county} -\usage{ -aqs_qa_pep_audit_by_county( - parameter, - bdate, - edate, - stateFIPS, - countycode, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be -returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. If TRUE -returns a AQSAPI_v2 object which is a two item -list that contains header information returned from -the API server mostly used for debugging purposes in -addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -assurance PEP audit data within a county. A AQS_Data_Mart_APIv2 -object is a 2 item named list in which the first item ($Header) is -a tibble of header information from the AQS API and the second item -($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a table of Performance Evaluation Program (PEP) audit -data aggregated by parameter code, stateFIPS and countycode -for the time frame between bdate and edate. -} -\note{ -The AQS API only allows for a single year of pep audit data -to be retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# returns a tibble with PEP Audit data for FRM - # PM2.5 in Madison County, AL for 2017 - \dontrun{aqs_qa_pep_audit_by_county_multiyear(parameter = "88101", - bdate = as.Date("20150101", - format = "\%Y\%m\%d" - ), - edate = as.Date("20171231", - format = "\%Y\%m\%d" - ), - stateFIPS = "01", - countycode = "089" - ) - } -} -\seealso{ -Other Aggregate _by_county functions: -\code{\link{aqs_annualsummary_by_county}()}, -\code{\link{aqs_dailysummary_by_county}()}, -\code{\link{aqs_monitors_by_county}()}, -\code{\link{aqs_qa_annualperformanceeval_by_county}()}, -\code{\link{aqs_qa_blanks_by_county}()}, -\code{\link{aqs_qa_collocated_assessments_by_county}()}, -\code{\link{aqs_qa_flowrateaudit_by_county}()}, -\code{\link{aqs_qa_flowrateverification_by_county}()}, -\code{\link{aqs_qa_one_point_qc_by_county}()}, -\code{\link{aqs_quarterlysummary_by_county}()}, -\code{\link{aqs_quarterlysummary_by_site}()}, -\code{\link{aqs_sampledata_by_county}()}, -\code{\link{aqs_transactionsample_by_county}()} -} -\concept{Aggregate _by_county functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_pep_audit_by_pqao.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_pep_audit_by_pqao.Rd deleted file mode 100644 index a4a96a8..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_pep_audit_by_pqao.Rd +++ /dev/null @@ -1,102 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bypqao.R -\name{aqs_qa_pep_audit_by_pqao} -\alias{aqs_qa_pep_audit_by_pqao} -\title{aqs_qa_pep_audit_by_pqao} -\usage{ -aqs_qa_pep_audit_by_pqao( - parameter, - bdate, - edate, - pqao_code, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{pqao_code}{a R character object which represents the 4 digit AQS -Primary Quality Assurance Organization code -(with leading zeroes).} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. If TRUE -returns a AQSAPI_v2 object which is a two item list that contains header -information returned from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -assurance PEP audit data for a Primary Quality Assurance -Organization. A AQS_Data_Mart_APIv2 object is a 2 item named list -in which the first item ($Header) is a tibble of header -information from the AQS API and the second item ($Data) is a -tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a table of Performance Evaluation Program (PEP) audit -data aggregated by Primary Quality Assurance Organization -(PQAO) code for the time frame between bdate and edate. -} -\note{ -The AQS API only allows for a single year of pep audit data -to be retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# returns a tibble of PEP audit data for - # June 2017 where the pqao is the Alabama Department of - # Environmental Management (agency 0013) - \dontrun{aqs_qa_pep_audit_by_pqao(parameter = "88101", - bdate = as.Date("20170601", - format = "\%Y\%m\%d" - ), - edate = as.Date("20190630", - format = "\%Y\%m\%d"), - pqao_code = "0013" - ) - } -} -\seealso{ -Other Aggregate _by_pqao functions: -\code{\link{aqs_qa_annualperformanceeval_by_pqao}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_pqao}()}, -\code{\link{aqs_qa_blanks_by_pqao}()}, -\code{\link{aqs_qa_collocated_assessments_by_pqao}()}, -\code{\link{aqs_qa_flowrateaudit_by_pqao}()}, -\code{\link{aqs_qa_flowrateverification_by_pqao}()}, -\code{\link{aqs_qa_one_point_qc_by_pqao}()} -} -\concept{Aggregate _by_pqao functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_pep_audit_by_site.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_pep_audit_by_site.Rd deleted file mode 100644 index fd480b9..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_pep_audit_by_site.Rd +++ /dev/null @@ -1,122 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bysite.R -\name{aqs_qa_pep_audit_by_site} -\alias{aqs_qa_pep_audit_by_site} -\title{aqs_qa_pep_audit_by_site} -\usage{ -aqs_qa_pep_audit_by_site( - parameter, - bdate, - edate, - stateFIPS, - countycode, - sitenum, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{sitenum}{a R character object which represents the 4 digit site number -(with leading zeros) within the county and state being -requested.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -assurance PEP audit data within a site. A AQS_Data_Mart_APIv2 -object is a 2 item named list in which the first item ($Header) is -a tibble of header information from the AQS API and the second item -($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a table of Performance Evaluation Program (PEP) audit -data aggregated by parameter code, stateFIPS, countycode and -site number for the time frame between bdate and edate. -} -\note{ -The AQS API only allows for a single year of pep audit data -to be retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# returns a tibble of pep Audit data for FRM PM2.5 - # at the Huntsville Old Airport site (\#0014) in Madison County, - # AL for 2017 - 2019. - \dontrun{aqs_qa_pep_audit_by_site(parameter = "88101", - bdate = as.Date("20170101", - format = "\%Y\%m\%d"), - edate = as.Date("20191231", - format = "\%Y\%m\%d"), - stateFIPS = "01", - countycode = "089", - sitenum = "0014" - ) - } -} -\seealso{ -Other Aggregate _by_site functions: -\code{\link{aqs_annualsummary_by_site}()}, -\code{\link{aqs_dailysummary_by_site}()}, -\code{\link{aqs_monitors_by_site}()}, -\code{\link{aqs_qa_annualperformanceeval_by_site}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_county}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_site}()}, -\code{\link{aqs_qa_blanks_by_site}()}, -\code{\link{aqs_qa_collocated_assessments_by_site}()}, -\code{\link{aqs_qa_flowrateaudit_by_site}()}, -\code{\link{aqs_qa_flowrateverification_by_site}()}, -\code{\link{aqs_qa_one_point_qc_by_site}()}, -\code{\link{aqs_sampledata_by_site}()}, -\code{\link{aqs_services_by_site}()}, -\code{\link{aqs_transactionsample_by_site}()} -} -\concept{Aggregate _by_site functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_pep_audit_by_state.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_pep_audit_by_state.Rd deleted file mode 100644 index 93f0db5..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_qa_pep_audit_by_state.Rd +++ /dev/null @@ -1,102 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bystate.R -\name{aqs_qa_pep_audit_by_state} -\alias{aqs_qa_pep_audit_by_state} -\title{aqs_qa_pep_audit_by_state} -\usage{ -aqs_qa_pep_audit_by_state( - parameter, - bdate, - edate, - stateFIPS, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. If TRUE -returns a AQSAPI_v2 object which is a two item -list that contains header information returned from -the API server mostly used for debugging purposes in -addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object containing quality -assurance PEP audit data within a state. A AQS_Data_Mart_APIv2 -object is a 2 item named list in which the first item ($Header) is -a tibble of header information from the AQS API and the second item -($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a table of Performance Evaluation Program (PEP) audit -data aggregated by parameter code, and stateFIPS for the time -frame between bdate and edate. -} -\note{ -The AQS API only allows for a single year of one point pep audit data -to be retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# returns a tibble of PEP audit data for PM2.5 in Alabama 2017 - \dontrun{aqs_qa_pep_audit_by_state_multiyear(parameter="88101", - bdate=as.Date("20160101", - format="\%Y\%m\%d"), - edate=as.Date("20171231", - format="\%Y\%m\%d"), - stateFIPS="01" - ) - } -} -\seealso{ -Other Aggregate_by_state functions: -\code{\link{aqs_annualsummary_by_state}()}, -\code{\link{aqs_dailysummary_by_state}()}, -\code{\link{aqs_monitors_by_state}()}, -\code{\link{aqs_qa_blanks_by_state}()}, -\code{\link{aqs_qa_collocated_assessments_by_state}()}, -\code{\link{aqs_qa_flowrateaudit_by_state}()}, -\code{\link{aqs_qa_flowrateverification_by_state}()}, -\code{\link{aqs_qa_one_point_qc_by_state}()}, -\code{\link{aqs_sampledata_by_state}()} -} -\concept{Aggregate_by_state functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_quarterlysummary_by_box.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_quarterlysummary_by_box.Rd deleted file mode 100644 index 305b1e2..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_quarterlysummary_by_box.Rd +++ /dev/null @@ -1,127 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bybox.R -\name{aqs_quarterlysummary_by_box} -\alias{aqs_quarterlysummary_by_box} -\title{aqs_quarterlysummary_by_box} -\usage{ -aqs_quarterlysummary_by_box( - parameter, - bdate, - edate, - minlat, - maxlat, - minlon, - maxlon, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{minlat}{a R character object which represents the minimum latitude of -a geographic box. Decimal latitude with north begin -positive. Only data north of this latitude will be -returned.} - -\item{maxlat}{a R character object which represents the maximum latitude of -a geographic box. Decimal latitude with north begin -positive. Only data south of this latitude will be -returned.} - -\item{minlon}{a R character object which represents the minimum longitude -of a geographic box. Decimal longitude with east begin -positive. Only data east of this longitude will be -returned.} - -\item{maxlon}{a R character object which represents the maximum longitude -of a geographic box. Decimal longitude with east begin -positive. Only data west of this longitude will be -returned. Note that -80 is less than -70.} - -\item{cbdate}{a R date object which represents a "beginning date of last -change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object that contains quarterly -summary statistics for an area within a latitude/longitude -bounding box. An AQS_Data Mart_APIv2 is a 2 item named list in -which the first item ($Header) is a tibble of header information -from the AQS API and the second item ($Data) is a tibble of the -data returned. -} -\description{ -\lifecycle{stable} -Returns a tibble or an AQS_Data Mart_APIv2 S3 -object of quarterly summary data aggregated by and area within -a latitude/longitude bounding box. -} -\note{ -The AQS API only allows for a single year of quarterly summary to be -retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). - -\if{html}{\out{
}}\preformatted{ Also Note that for quarterly data, only the year portion of the bdate - and edate are used and all 4 quarters in the year are returned. -}\if{html}{\out{
}} -} -\examples{ -# Returns a tibble containing ozone quarterly summaries - # in the vicinity of central Alabama for each quarter in - # between 2015 - 2017 - \dontrun{aqs_quarterlysummary_by_box(parameter = "44201", - bdate = as.Date("20150101", - format = "\%Y\%m\%d"), - edate = as.Date("20171231", - format = "\%Y\%m\%d"), - minlat = "33.3", - maxlat = "33.6", - minlon = "-87.0", - maxlon = "-86.7" - ) - } -} -\seealso{ -Other Aggregate _by_state functions: -\code{\link{aqs_qa_annualperformanceeval_by_state}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_state}()}, -\code{\link{aqs_quarterlysummary_by_cbsa}()}, -\code{\link{aqs_quarterlysummary_by_state}()}, -\code{\link{aqs_transactionsample_by_MA}()}, -\code{\link{aqs_transactionsample_by_state}()} -} -\concept{Aggregate _by_state functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_quarterlysummary_by_cbsa.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_quarterlysummary_by_cbsa.Rd deleted file mode 100644 index 7e5c3cf..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_quarterlysummary_by_cbsa.Rd +++ /dev/null @@ -1,103 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bycbsa.R -\name{aqs_quarterlysummary_by_cbsa} -\alias{aqs_quarterlysummary_by_cbsa} -\title{aqs_quarterlysummary_by_cbsa} -\usage{ -aqs_quarterlysummary_by_cbsa( - parameter, - bdate, - edate, - cbsa_code, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{cbsa_code}{a R character object which represents the 5 digit AQS Core -Based Statistical Area code (the same as the census code, -with leading zeros)} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object that contains quarterly -summary statistics for the given parameter for a stateFIPS. -An AQS_Data Mart_APIv2 is a 2 item named list in which the first -item ($Header) is a tibble of header information from the AQS API -and the second item ($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a tibble or an AQS_Data Mart_APIv2 S3 -object of quarterly summary data aggregated by stateFIPS. -} -\note{ -The AQS API only allows for a single year of quarterly summary to be -retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). - -\if{html}{\out{
}}\preformatted{ Also Note that for quarterly data, only the year portion of the bdate - and edate are used and all 4 quarters in the year are returned. -}\if{html}{\out{
}} -} -\examples{ -# Returns a tibble of $NO_{2}$ quartyerly summary - # data the for Charlotte-Concord-Gastonia, NC cbsa for - # each quarter in 2017. - \dontrun{aqs_quarterlysummary_by_cbsa(parameter = "42602", - bdate = as.Date("20170101", - format = "\%Y\%m\%d"), - edate = as.Date("20171231", - format = "\%Y\%m\%d"), - cbsa_code = "16740" - ) - } -} -\seealso{ -Other Aggregate _by_state functions: -\code{\link{aqs_qa_annualperformanceeval_by_state}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_state}()}, -\code{\link{aqs_quarterlysummary_by_box}()}, -\code{\link{aqs_quarterlysummary_by_state}()}, -\code{\link{aqs_transactionsample_by_MA}()}, -\code{\link{aqs_transactionsample_by_state}()} -} -\concept{Aggregate _by_state functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_quarterlysummary_by_county.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_quarterlysummary_by_county.Rd deleted file mode 100644 index 9b8a176..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_quarterlysummary_by_county.Rd +++ /dev/null @@ -1,120 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bycounty.R -\name{aqs_quarterlysummary_by_county} -\alias{aqs_quarterlysummary_by_county} -\title{aqs_quarterlysummary_by_county} -\usage{ -aqs_quarterlysummary_by_county( - parameter, - bdate, - edate, - stateFIPS, - countycode, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be -returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object that contains quarterly -summary statistics for the given parameter for a single countycode -and stateFIPS combination. An AQS_Data Mart_APIv2 is a 2 item named -list in which the first item ($Header) is a tibble of header -information from the AQS API and the second item ($Data) is a -tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a tibble or an AQS_Data Mart_APIv2 S3 -object of quarterly summary data aggregated by cbsa -(Core Based Statistical Area) code. -} -\note{ -The AQS API only allows for a single year of quarterly summary to be -retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). - -\if{html}{\out{
}}\preformatted{ Also Note that for quarterly data, only the year portion of the bdate - and edate are used and all 4 quarters in the year are returned. -}\if{html}{\out{
}} -} -\examples{ -# returns a tibble containing quarterly summaries for - # FRM/FEM PM2.5 data for Wake County, NC for each quarter of 2016 - \dontrun{aqs_quarterlysummary_by_county(parameter = "88101", - bdate = as.Date("20160101", - format = "\%Y\%m\%d"), - edate = as.Date("20170228", - format = "\%Y\%m\%d"), - stateFIPS = "37", - countycode = "183" - ) - } -} -\seealso{ -Other Aggregate _by_county functions: -\code{\link{aqs_annualsummary_by_county}()}, -\code{\link{aqs_dailysummary_by_county}()}, -\code{\link{aqs_monitors_by_county}()}, -\code{\link{aqs_qa_annualperformanceeval_by_county}()}, -\code{\link{aqs_qa_blanks_by_county}()}, -\code{\link{aqs_qa_collocated_assessments_by_county}()}, -\code{\link{aqs_qa_flowrateaudit_by_county}()}, -\code{\link{aqs_qa_flowrateverification_by_county}()}, -\code{\link{aqs_qa_one_point_qc_by_county}()}, -\code{\link{aqs_qa_pep_audit_by_county}()}, -\code{\link{aqs_quarterlysummary_by_site}()}, -\code{\link{aqs_sampledata_by_county}()}, -\code{\link{aqs_transactionsample_by_county}()} -} -\concept{Aggregate _by_county functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_quarterlysummary_by_site.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_quarterlysummary_by_site.Rd deleted file mode 100644 index 638fa89..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_quarterlysummary_by_site.Rd +++ /dev/null @@ -1,126 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bysite.R -\name{aqs_quarterlysummary_by_site} -\alias{aqs_quarterlysummary_by_site} -\title{aqs_quarterlysummary_by_site} -\usage{ -aqs_quarterlysummary_by_site( - parameter, - bdate, - edate, - stateFIPS, - countycode, - sitenum, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{sitenum}{a R character object which represents the 4 digit site number -(with leading zeros) within the county and state being -requested.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object that contains quarterly -summary statistics for the given parameter for a single countycode -and stateFIPS combination. An AQS_Data Mart_APIv2 is a 2 item named -list in which the first item ($Header) is a tibble of header -information from the AQS API and the second item ($Data) is a -tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a tibble or an AQS_Data Mart_APIv2 S3 object of quarterly summary -data aggregated by site with the provided parameternum, stateFIPS, -county_code, and sitenum for bdate - edate time frame. -} -\note{ -The AQS API only allows for a single year of quarterly summary to be -retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). - -\if{html}{\out{
}}\preformatted{ Also Note that for quarterly data, only the year portion of the bdate - and edate are used and all 4 quarters in the year are returned. -}\if{html}{\out{
}} -} -\examples{ -# returns a tibble containing quarterly summaries for - # FRM/FEM PM2.5 data for Millbrook School in Wake County, NC - # for each quarter of 2016 - \dontrun{aqs_quarterlysummary_by_site(parameter = "88101", - bdate = as.Date("20160101", - format = "\%Y\%m\%d"), - edate = as.Date("20160331", - format = "\%Y\%m\%d"), - stateFIPS = "37", - countycode = "183", - sitenum = "0014" - ) - } -} -\seealso{ -Other Aggregate _by_county functions: -\code{\link{aqs_annualsummary_by_county}()}, -\code{\link{aqs_dailysummary_by_county}()}, -\code{\link{aqs_monitors_by_county}()}, -\code{\link{aqs_qa_annualperformanceeval_by_county}()}, -\code{\link{aqs_qa_blanks_by_county}()}, -\code{\link{aqs_qa_collocated_assessments_by_county}()}, -\code{\link{aqs_qa_flowrateaudit_by_county}()}, -\code{\link{aqs_qa_flowrateverification_by_county}()}, -\code{\link{aqs_qa_one_point_qc_by_county}()}, -\code{\link{aqs_qa_pep_audit_by_county}()}, -\code{\link{aqs_quarterlysummary_by_county}()}, -\code{\link{aqs_sampledata_by_county}()}, -\code{\link{aqs_transactionsample_by_county}()} -} -\concept{Aggregate _by_county functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_quarterlysummary_by_state.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_quarterlysummary_by_state.Rd deleted file mode 100644 index 31bf4ff..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_quarterlysummary_by_state.Rd +++ /dev/null @@ -1,103 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bystate.R -\name{aqs_quarterlysummary_by_state} -\alias{aqs_quarterlysummary_by_state} -\title{aqs_quarterlysummary_by_state} -\usage{ -aqs_quarterlysummary_by_state( - parameter, - bdate, - edate, - stateFIPS, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object that contains quarterly -summary statistics for the given parameter for a stateFIPS. -An AQS_Data Mart_APIv2 is a 2 item named list in which the first -item ($Header) is a tibble of header information from the AQS API -and the second item ($Data) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns a tibble or an AQS_Data Mart_APIv2 S3 -object of quarterly summary data aggregated by stateFIPS. -} -\note{ -The AQS API only allows for a single year of quarterly summary to be -retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of data -at a time. Each calendar year of data requires a separate API call so -multiple years of data will require multiple API calls. As the number -of years of data being requested increases so does the length of time -that it will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). - -\if{html}{\out{
}}\preformatted{ Also Note that for quarterly data, only the year portion of the bdate - and edate are used and all 4 quarters in the year are returned. -}\if{html}{\out{
}} -} -\examples{ -# Returns an aqs S3 object containing quarterly summaries for - # FRM/FEM PM2.5 data for North Carolina for each quater of 2016 - \dontrun{aqs_quarterlysummary_by_state(parameter = "88101", - bdate = as.Date("20160101", - format = "\%Y\%m\%d"), - edate = as.Date("20171231", - format = "\%Y\%m\%d"), - stateFIPS = "37" - ) - } -} -\seealso{ -Other Aggregate _by_state functions: -\code{\link{aqs_qa_annualperformanceeval_by_state}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_state}()}, -\code{\link{aqs_quarterlysummary_by_box}()}, -\code{\link{aqs_quarterlysummary_by_cbsa}()}, -\code{\link{aqs_transactionsample_by_MA}()}, -\code{\link{aqs_transactionsample_by_state}()} -} -\concept{Aggregate _by_state functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_removeheader.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_removeheader.Rd deleted file mode 100644 index 91d27fc..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_removeheader.Rd +++ /dev/null @@ -1,34 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/RAQSAPIlistfunctions.R -\name{aqs_removeheader} -\alias{aqs_removeheader} -\title{aqs_removeheader} -\usage{ -aqs_removeheader(AQSobject) -} -\arguments{ -\item{AQSobject}{An object of AQSAPI_v2 or a list of AQSAPI_v2 objects.} -} -\value{ -a tibble of the combined $data portions of the input -AQS_Data_Mart_APIv2 S3 object with the $Header portion discarded. -} -\description{ -\lifecycle{stable} -Coerces a single AQS_Data_Mart_APIv2 S3 object or -a list of AQS_Data_Mart_APIv2 S3 objects into a single tibble -object. This function decouples the $Data from the AQSAPI_v2 -object and returns only the $Data portion as a tibble. If the -input is a list of AQSAPI_v2 objects combines the $Data -portion of each AQS_Data_Mart_APIv2 S3 object into a single -tibble with $Header information discarded. Else returns the -input with no changes. -} -\note{ -Since this function returns only the $Data portion of RAQSAPI_v2 -objects this means that the $Header information will not be present in the -object being returned. -} -\examples{ - \dontrun{ AQSobject <- aqs_removeheader(AQSobject)} -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_revisionhistory.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_revisionhistory.Rd deleted file mode 100644 index 6531554..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_revisionhistory.Rd +++ /dev/null @@ -1,29 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/RAQSAPIlistfunctions.R -\name{aqs_revisionhistory} -\alias{aqs_revisionhistory} -\title{aqs_revisionhistory} -\usage{ -aqs_revisionhistory(return_header = FALSE) -} -\arguments{ -\item{return_header}{If FALSE (default) only returns data requested. If TRUE -returns a AQSAPI_v2 object which is a two item list that contains header -information returned from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object that is the return value -from the AQS API. A AQS_Data Mart_APIv2 is a 2 item named list in which the -first item ($Header) is a tibble of header information from the AQS API -and the second item ($Data) is a tibble of the data -returned. -} -\description{ -\lifecycle{stable} -Returns the change history to the AQS Data Mart API. -} -\examples{ - # Returns a DataFrame of the EPA AQS Data Mart API revision history - # \dontrun{aqs_revisionHistory()} -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sampledata_by_box.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sampledata_by_box.Rd deleted file mode 100644 index 21f2d1e..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sampledata_by_box.Rd +++ /dev/null @@ -1,141 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bybox.R -\name{aqs_sampledata_by_box} -\alias{aqs_sampledata_by_box} -\title{aqs_sampledata_by_box} -\usage{ -aqs_sampledata_by_box( - parameter, - bdate, - edate, - minlat, - maxlat, - minlon, - maxlon, - duration = NA_character_, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{minlat}{a R character object which represents the minimum latitude of -a geographic box. Decimal latitude with north begin -positive. Only data north of this latitude will be -returned.} - -\item{maxlat}{a R character object which represents the maximum latitude of -a geographic box. Decimal latitude with north begin -positive. Only data south of this latitude will be -returned.} - -\item{minlon}{a R character object which represents the minimum longitude -of a geographic box. Decimal longitude with east begin -positive. Only data east of this longitude will be -returned.} - -\item{maxlon}{a R character object which represents the maximum longitude -of a geographic box. Decimal longitude with east begin -positive. Only data west of this longitude will be -returned. Note that -80 is less than -70.} - -\item{duration}{an optional R character string that represents the -parameter duration code that limits returned data -to a specific sample duration. The default value of -NA_character_ results in no filtering based on -duration code.Valid durations include actual sample -durations and not calculated durations such as 8 -hour CO or $O_3$ rolling averages, 3/6 day PM -averages or Pb 3 month rolling averages. -@seealso \code{\link[=aqs_sampledurations]{aqs_sampledurations()}} for a list of all -available duration codes.} - -\item{cbdate}{a R date object which represents a "beginning date of last -change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two item -list that contains header information returned from -the API server mostly used for debugging purposes in -addition to the data requested.} -} -\value{ -a tibble or an AQS_Data_Mart_APIv2 S3 object containing sample data -for all monitors within the input latitude/longitude bounding box -for a single parameter. An AQS_Data Mart_APIv2 is a 2 item named -list in which the first item /(/$Header/) is a tibble of header -information from the AQS API and the second item /(/$Data/) is a -tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns sample data where the data is aggregated by -latitude/longitude bounding box (_by_box). -If return_header is FALSE (default) this function returns a -single dataframe with the requested data. If return_header -is TRUE returns a list of AQSAPI_v2 objects where each index -of the list is an individual RAQSAPI_v2 object returned from -each successive call to the AQS API. RAQSAPI_v2 objects are -two item list where the $Data portion contains data that -contains sample air monitoring data at a site with the input -parameter and cbsa_code provided for bdate - edate time -frame. The $Header is a tibble of header information from the -API call /(useful for debugging/). This function returns NULL -is bdate > edate. -} -\note{ -The AQS API only allows for a single year of sampledata to be retrieved -at a time. This function conveniently extracts date information from -the bdate and edate parameters then makes repeated calls to the -AQSAPI retrieving a maximum of one calendar year of data at a time. -Each calendar year of data requires a separate API call so multiple -years of data will require multiple API calls. As the number of years -of data being requested increases so does the length of time that it -will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# Returns a tibble containing all ozone samples - # in the vicinity of central Alabama between - # May 1, 2015 - May 2, 2017 - \dontrun{aqs_sampledata_by_box(parameter = "44201", - bdate = as.Date("20150501", - format = "\%Y\%m\%d"), - edate = as.Date("20170502", - format = "\%Y\%m\%d"), - minlat = "33.3", - maxlat = "33.6", - minlon = "-87.0", - maxlon = "-86.7" - ) - } -} -\seealso{ -Other Aggregate _by_box functions: -\code{\link{aqs_annualsummary_by_box}()}, -\code{\link{aqs_monitors_by_box}()} -} -\concept{Aggregate _by_box functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sampledata_by_cbsa.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sampledata_by_cbsa.Rd deleted file mode 100644 index ece3dd0..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sampledata_by_cbsa.Rd +++ /dev/null @@ -1,119 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bycbsa.R -\name{aqs_sampledata_by_cbsa} -\alias{aqs_sampledata_by_cbsa} -\title{aqs_sampledata_by_cbsa} -\usage{ -aqs_sampledata_by_cbsa( - parameter, - bdate, - edate, - cbsa_code, - duration = NA_character_, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{cbsa_code}{a R character object which represents the 5 digit AQS Core -Based Statistical Area code (the same as the census code, -with leading zeros)} - -\item{duration}{an optional R character string that represents the -parameter duration code that limits returned data -to a specific sample duration. The default value of -NA_character_ results in no filtering based on -duration code.Valid durations include actual sample -durations and not calculated durations such as 8 -hour CO or $O_3$ rolling averages, 3/6 day PM -averages or Pb 3 month rolling averages. -@seealso \code{\link[=aqs_sampledurations]{aqs_sampledurations()}} for a list of all -available duration codes.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two item -list that contains header information returned from -the API server mostly used for debugging purposes in -addition to the data requested.} -} -\value{ -a tibble or an AQS_Data_Mart_APIv2 S3 object containing sample data -for all monitors matching cbsa_code for the given parameter. An -AQS_Data Mart_APIv2 is a 2 item named list in which the first item -/(/$Header/) is a tibble of header information from the AQS API and -the second item /(/$Data/) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns sample data where the data is aggregated at the Core -Based Statistical Area (cbsa) level. If return_header is -FALSE (default) this function returns a single dataframe with -the requested data. If return_header is TRUE returns a list -of AQSAPI_v2 objects where each index of the list is an -individual RAQSAPI_v2 object returned from each successive -call to the AQS API. RAQSAPI_v2 objects are two item list -where the $Data portion contains data that contains -sample air monitoring data at a site with the input -parameter and cbsa_code provided for -bdate - edate time frame. The $Header is a tibble of -header information from the API call /(useful for -debugging/). This function returns NULL is bdate > edate. -} -\note{ -The AQS API only allows for a single year of sampledata to be retrieved -at a time. This function conveniently extracts date information from -the bdate and edate parameters then makes repeated calls to the -AQSAPI retrieving a maximum of one calendar year of data at a time. -Each calendar year of data requires a separate API call so multiple -years of data will require multiple API calls. As the number of years -of data being requested increases so does the length of time that it -will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. Fortunately this operation has a linear run time -/(Big O notation: O/(n + 5 seconds/)/) -} -\examples{ -# returns tibble which contains $NO_{2}$ data - # for Charlotte-Concord-Gastonia, NC cbsa for - # Janurary 1, 2015 - Janurary 01, 2017 - \dontrun{aqs_sampledata_by_cbsa(parameter = "42602", - bdate = as.Date("20150101", - format = "\%Y\%m\%d"), - edate = as.Date("20170101", - format = "\%Y\%m\%d"), - cbsa_code = "16740" - ) - } -} -\seealso{ -Other Aggregate _by_cbsa functions: -\code{\link{aqs_annualsummary_by_cbsa}()}, -\code{\link{aqs_dailysummary_by_cbsa}()}, -\code{\link{aqs_monitors_by_cbsa}()} -} -\concept{Aggregate _by_cbsa functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sampledata_by_county.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sampledata_by_county.Rd deleted file mode 100644 index c42a2dd..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sampledata_by_county.Rd +++ /dev/null @@ -1,136 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bycounty.R -\name{aqs_sampledata_by_county} -\alias{aqs_sampledata_by_county} -\title{aqs_sampledata_by_county} -\usage{ -aqs_sampledata_by_county( - parameter, - bdate, - edate, - stateFIPS, - countycode, - duration = NA_character_, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be -returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{duration}{an optional R character string that represents the -parameter duration code that limits returned data -to a specific sample duration. The default value of -NA_character_ results in no filtering based on -duration code.Valid durations include actual sample -durations and not calculated durations such as 8 -hour CO or $O_3$ rolling averages, 3/6 day PM -averages or Pb 3 month rolling averages. -@seealso \code{\link[=aqs_sampledurations]{aqs_sampledurations()}} for a list of all -available duration codes.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two item -list that contains header information returned from -the API server mostly used for debugging purposes in -addition to the data requested.} -} -\value{ -a tibble or an AQS_Data_Mart_APIv2 S3 object containing sample data -for all monitors matching stateFIPS and county_code for the given -parameter. An AQS_Data Mart_APIv2 is a 2 item named list in which -the first item /(/$Header/) is a tibble of header information from -the AQS API and the second item /(/$Data/) is a tibble of the data -returned. -} -\description{ -\lifecycle{stable} -Returns a single tibble with the requested data. If -return_header is TRUE returns a list -of AQSAPI_v2 objects where each index of the list is an -individual RAQSAPI_v2 object returned from each successive -call to the AQS API. RAQSAPI_v2 objects are two item list -where the $Data portion contains data that contains -sample air monitoring data at a site with the input -parameter, stateFIPS and county_code provided for -bdate - edate time frame. The $Header is a tibble of -header information from the API call /(useful for -debugging/). This function returns NULL is bdate > edate. -} -\note{ -The AQS API only allows for a single year of sampledata to be retrieved -at a time. This function conveniently extracts date information from -the bdate and edate parameters then makes repeated calls to the -AQSAPI retrieving a maximum of one calendar year of data at a time. -Each calendar year of data requires a separate API call so multiple -years of data will require multiple API calls. As the number of years -of data being requested increases so does the length of time that it -will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# returns all FRM/FEM PM2.5 data for Wake County, NC between - # January 1, 2015 - February 28, 2016 - \dontrun{aqs_sampledata_by_county(parameter = "88101", - bdate = as.Date("20150101", - format = "\%Y\%m\%d"), - edate=as.Date("20160228", - format = "\%Y\%m\%d"), - stateFIPS = "37", - countycode = "183" - ) - } -} -\seealso{ -Other Aggregate _by_county functions: -\code{\link{aqs_annualsummary_by_county}()}, -\code{\link{aqs_dailysummary_by_county}()}, -\code{\link{aqs_monitors_by_county}()}, -\code{\link{aqs_qa_annualperformanceeval_by_county}()}, -\code{\link{aqs_qa_blanks_by_county}()}, -\code{\link{aqs_qa_collocated_assessments_by_county}()}, -\code{\link{aqs_qa_flowrateaudit_by_county}()}, -\code{\link{aqs_qa_flowrateverification_by_county}()}, -\code{\link{aqs_qa_one_point_qc_by_county}()}, -\code{\link{aqs_qa_pep_audit_by_county}()}, -\code{\link{aqs_quarterlysummary_by_county}()}, -\code{\link{aqs_quarterlysummary_by_site}()}, -\code{\link{aqs_transactionsample_by_county}()} -} -\concept{Aggregate _by_county functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sampledata_by_site.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sampledata_by_site.Rd deleted file mode 100644 index 8f97892..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sampledata_by_site.Rd +++ /dev/null @@ -1,147 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bysite.R -\name{aqs_sampledata_by_site} -\alias{aqs_sampledata_by_site} -\title{aqs_sampledata_by_site} -\usage{ -aqs_sampledata_by_site( - parameter, - bdate, - edate, - stateFIPS, - countycode, - sitenum, - duration = NA_character_, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{sitenum}{a R character object which represents the 4 digit site number -(with leading zeros) within the county and state being -requested.} - -\item{duration}{an optional R character string that represents the -parameter duration code that limits returned data -to a specific sample duration. The default value of -NA_character_ results in no filtering based on -duration code.Valid durations include actual sample -durations and not calculated durations such as 8 -hour CO or $O_3$ rolling averages, 3/6 day PM -averages or Pb 3 month rolling averages. -@seealso \code{\link[=aqs_sampledurations]{aqs_sampledurations()}} for a list of all -available duration codes.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) returns a single data frame with the -data requested. If TRUE returns a AQSAPI_v2 object -which is a two item list that contains header -information returned from the API server mostly used -for debugging purposes in addition to the data -requested. This is mostly useful for debugging -purposes, in case the user wishes to see the header -information from each api call.} -} -\value{ -a tibble or an AQS_Data_Mart_APIv2 S3 object containing sample data -for a single site with the input parameter. An AQS_Data Mart_APIv2 -is a 2 item named list in which the first item /(/$Header/) is a -tibble of header information from the AQS API and the second item -/(/$Data/) is a tibble of the data returned. -} -\description{ -\lifecycle{stable} -Returns multiple years of data where sample data is -aggregated at the site level. If return_header is -FALSE (default) returns a single data frame with -the requested data. If return_header is TRUE returns a list -of AQSAPI_v2 objects where each index of the list is an -individual RAQSAPI_v2 object returned from each successive -calls to the AQS API. RAQSAPI_v2 objects are two item list -where the $Data portion contains data that contains -sample air monitoring data at a site with the input -parameter, stateFIPS and county_code provided for -bdate - edate time frame. The $Header is a tibble of -header information from the API call /(useful for -debugging/). Returns NULL is bdate > edate. -} -\note{ -The AQS API only allows for a single year of sampledata to be retrieved -at a time. This function conveniently extracts date information from -the bdate and edate parameters then makes repeated calls to the -AQSAPI retrieving a maximum of one calendar year of data at a time. -Each calendar year of data requires a separate API call so multiple -years of data will require multiple API calls. As the number of years -of data being requested increases so does the length of time that it -will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -#Returns a table of ozone monitoring data for the Millbrook School - # site (/#0014) in Wake County, NC for June 18, 2017. - \dontrun{ - aqs_sampledata_by_site(parameter = "44201", - bdate = as.Date("20170618", - format = "\%Y\%m\%d"), - edate = as.Date("20190618", - format = "\%Y\%m\%d"), - stateFIPS = "37", - countycode = "183", - sitenum = "0014" - ) - } -} -\seealso{ -Other Aggregate _by_site functions: -\code{\link{aqs_annualsummary_by_site}()}, -\code{\link{aqs_dailysummary_by_site}()}, -\code{\link{aqs_monitors_by_site}()}, -\code{\link{aqs_qa_annualperformanceeval_by_site}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_county}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_site}()}, -\code{\link{aqs_qa_blanks_by_site}()}, -\code{\link{aqs_qa_collocated_assessments_by_site}()}, -\code{\link{aqs_qa_flowrateaudit_by_site}()}, -\code{\link{aqs_qa_flowrateverification_by_site}()}, -\code{\link{aqs_qa_one_point_qc_by_site}()}, -\code{\link{aqs_qa_pep_audit_by_site}()}, -\code{\link{aqs_services_by_site}()}, -\code{\link{aqs_transactionsample_by_site}()} -} -\concept{Aggregate _by_site functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sampledata_by_state.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sampledata_by_state.Rd deleted file mode 100644 index b4c0ab8..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sampledata_by_state.Rd +++ /dev/null @@ -1,126 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bystate.R -\name{aqs_sampledata_by_state} -\alias{aqs_sampledata_by_state} -\title{aqs_sampledata_by_state} -\usage{ -aqs_sampledata_by_state( - parameter, - bdate, - edate, - stateFIPS, - duration = NA_character_, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{duration}{an optional R character string that represents the -parameter duration code that limits returned data -to a specific sample duration. The default value of -NA_character_ results in no filtering based on -duration code.Valid durations include actual sample -durations and not calculated durations such as 8 -hour CO or $O_3$ rolling averages, 3/6 day PM -averages or Pb 3 month rolling averages. -@seealso \code{\link[=aqs_sampledurations]{aqs_sampledurations()}} for a list of all -available duration codes.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two item -list that contains header information returned from -the API server mostly used for debugging purposes in -addition to the data requested.} -} -\value{ -a tibble or an AQS_Data_Mart_APIv2 S3 object containing sample data -for all monitors matching stateFIPS for the given parameter. -An AQS_Data Mart_APIv2 is a 2 item named list in which the first -item /(/$Header/) is a tibble of header information from the -AQS API and the second item /(/$Data/) is a tibble of the data -returned. -} -\description{ -\lifecycle{stable} -Returns sample data where the data is aggregated at the state -level. If return_header is FALSE (default) this function -returns a single dataframe with the requested data. If -return_header is TRUE returns a list of AQSAPI_v2 objects -where each index of the list is an individual RAQSAPI_v2 -object returned from each successive call to the AQS API. -RAQSAPI_v2 objects are two item list where the $Data portion -contains data that contains sample air monitoring data at a -site with the input parameter and stateFIPS provided for -bdate - edate time frame. The $Header is a tibble of header -information from the API call /(useful for debugging/). This -function returns NULL is bdate > edate. -} -\note{ -The AQS API only allows for a single year of sampledata to be retrieved -at a time. This function conveniently extracts date information from -the bdate and edate parameters then makes repeated calls to the -AQSAPI retrieving a maximum of one calendar year of data at a time. -Each calendar year of data requires a separate API call so multiple -years of data will require multiple API calls. As the number of years -of data being requested increases so does the length of time that it -will take to retrieve results. There is also a 5 second wait -time inserted between successive API calls to prevent overloading the -API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -# Returns a tibble with all benzene samples from - # North Carolina collected from May 15th, 1995 - May 15, 1999 - \dontrun{aqs_sampledata_by_state(parameter = "45201", - bdate = as.Date("19950515", - format="\%Y\%m\%d" - ), - edate = as.Date("19990515", - format = "\%Y\%m\%d"), - stateFIPS = "37" - ) - } -} -\seealso{ -Other Aggregate_by_state functions: -\code{\link{aqs_annualsummary_by_state}()}, -\code{\link{aqs_dailysummary_by_state}()}, -\code{\link{aqs_monitors_by_state}()}, -\code{\link{aqs_qa_blanks_by_state}()}, -\code{\link{aqs_qa_collocated_assessments_by_state}()}, -\code{\link{aqs_qa_flowrateaudit_by_state}()}, -\code{\link{aqs_qa_flowrateverification_by_state}()}, -\code{\link{aqs_qa_one_point_qc_by_state}()}, -\code{\link{aqs_qa_pep_audit_by_state}()} -} -\concept{Aggregate_by_state functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sampledurations.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sampledurations.Rd deleted file mode 100644 index 2c8e789..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sampledurations.Rd +++ /dev/null @@ -1,31 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/RAQSAPIlistfunctions.R -\name{aqs_sampledurations} -\alias{aqs_sampledurations} -\title{aqs_sampledurations} -\usage{ -aqs_sampledurations(return_header = FALSE) -} -\arguments{ -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object of sample durations and -their associated duration codes -(groups of parameters, i.e. "criteria" or "all"). -} -\description{ -\lifecycle{stable} -Returns a table of sample durations and their -associated duration codes. Returned values are not calculated -durations such as 8 hour CO or O${_3}$ rolling averages, 3/6 -day PM averages or Pb 3 month rolling averages. -} -\examples{ -# Returns a tibble or an AQS_Data Mart_APIv2 S3 object of - \dontrun{ aqs_sampledurations() } -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_MA.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_MA.Rd deleted file mode 100644 index a274715..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_MA.Rd +++ /dev/null @@ -1,68 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/AQSAPI_helperfunctions.R -\name{aqs_services_by_MA} -\alias{aqs_services_by_MA} -\title{aqs_services_by_MA} -\usage{ -aqs_services_by_MA( - parameter, - bdate, - edate, - MA_code, - service, - cbdate = NA_Date_, - cedate = NA_Date_, - AQS_domain = "aqs.epa.gov" -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be -returned.} - -\item{MA_code}{a R character object which represents the 4 digit AQS -Monitoring Agency code (with leading zeroes).} - -\item{service}{a string which represents the services provided by the AQS API -For a list of available services @seealso -\url{https://aqs.epa.gov/aqsweb/documents/data_api.html#services}} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{AQS_domain}{a R string object containing the domain that should be -used in constructing the API call.} -} -\value{ -a AQS_DATAMART_APIv2 S3 object that is the return value from the -AQS API. A AQS_DATAMART_APIv2 is a 2 item named list in which the -first item ($Header) is a tibble of header information from the -AQS API and the second item ($Data) is a tibble of the data -returned. -} -\description{ -a helper function that abstracts the formatting of the inputs -for a call to aqs away from the calling function for -aggregations by Monitoring Agency (MA) -then calls the aqs and returns the result. -This helper function is not meant to be called directly from -external functions. -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_box.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_box.Rd deleted file mode 100644 index b71e6c0..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_box.Rd +++ /dev/null @@ -1,99 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/AQSAPI_helperfunctions.R -\name{aqs_services_by_box} -\alias{aqs_services_by_box} -\title{aqs_services_by_box} -\usage{ -aqs_services_by_box( - parameter, - bdate, - edate, - minlat, - maxlat, - minlon, - maxlon, - duration = NA_character_, - service, - cbdate = NA_Date_, - cedate = NA_Date_, - AQS_domain = "aqs.epa.gov" -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{minlat}{a R character object which represents the minimum latitude of -a geographic box. Decimal latitude with north begin -positive. Only data north of this latitude will be -returned.} - -\item{maxlat}{a R character object which represents the maximum latitude of -a geographic box. Decimal latitude with north begin -positive. Only data south of this latitude will be -returned.} - -\item{minlon}{a R character object which represents the minimum longitude -of a geographic box. Decimal longitude with east begin -positive. Only data east of this longitude will be -returned.} - -\item{maxlon}{a R character object which represents the maximum longitude -of a geographic box. Decimal longitude with east begin -positive. Only data west of this longitude will be -returned. Note that -80 is less than -70.} - -\item{duration}{an optional R character string that represents the -parameter duration code that limits returned data -to a specific sample duration. The default value of -NA_character_ results in no filtering based on -duration code.Valid durations include actual sample -durations and not calculated durations such as 8 -hour CO or $O_3$ rolling averages, 3/6 day PM -averages or Pb 3 month rolling averages. -@seealso \code{\link[=aqs_sampledurations]{aqs_sampledurations()}} for a list of all -available duration codes.} - -\item{service}{a string which represents the services provided by the -AQS API. For a list of available services @seealso -\url{https://aqs.epa.gov/aqsweb/documents/data_api.html#services}} - -\item{cbdate}{a R date object which represents a "beginning date of last -change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{AQS_domain}{a R string object containing the domain that should be -used in constructing the API call.} -} -\value{ -a AQS_DATAMART_APIv2 S3 object that is the return value from the -AQS API. A AQS_DATAMART_APIv2 is a 2 item named list in which the -first item ($Header) is a tibble of header information from the -AQS API and the second item ($Data) is a tibble of the data -returned. -} -\description{ -a helper function that abstracts the formatting of the inputs -for a call to aqs away from the calling function for -aggregations by a box formed by minimum/maximum -latitude/longitude coordinates then calls the aqs -and returns the result. This helper function is not meant -to be called directly from external functions. -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_cbsa.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_cbsa.Rd deleted file mode 100644 index 1c8ce5e..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_cbsa.Rd +++ /dev/null @@ -1,79 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/AQSAPI_helperfunctions.R -\name{aqs_services_by_cbsa} -\alias{aqs_services_by_cbsa} -\title{aqs_services_by_cbsa} -\usage{ -aqs_services_by_cbsa( - parameter, - bdate, - edate, - cbsa_code, - duration = NA_character_, - service, - cbdate = NA_Date_, - cedate = NA_Date_, - AQS_domain = "aqs.epa.gov" -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{cbsa_code}{a R character object which represents the 5 digit AQS Core -Based Statistical Area code (the same as the census code, -with leading zeros)} - -\item{duration}{an optional R character string that represents the -parameter duration code that limits returned data -to a specific sample duration. The default value of -NA_character_ results in no filtering based on -duration code.Valid durations include actual sample -durations and not calculated durations such as 8 -hour CO or $O_3$ rolling averages, 3/6 day PM -averages or Pb 3 month rolling averages. -@seealso \code{\link[=aqs_sampledurations]{aqs_sampledurations()}} for a list of all -available duration codes.} - -\item{service}{a string which represents the services provided by the AQS -API For a list of available services @seealso -\url{https://aqs.epa.gov/aqsweb/documents/data_api.html#services}} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{AQS_domain}{a R string object containing the domain that should be -used in constructing the API call.} -} -\value{ -a AQS_DATAMART_APIv2 S3 object that is the return value from the -AQS API. A AQS_DATAMART_APIv2 is a 2 item named list in which the -first item ($Header) is a tibble of header information from the -AQS API and the second item ($Data) is a tibble of the data -returned. -} -\description{ -a helper function that abstracts the formatting of the inputs -for a call to aqs away from the calling function for -aggregations by cbsa then calls the aqs and returns the -result. This helper function is not meant to be called -directly from external functions. -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_county.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_county.Rd deleted file mode 100644 index 38490b8..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_county.Rd +++ /dev/null @@ -1,87 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/AQSAPI_helperfunctions.R -\name{aqs_services_by_county} -\alias{aqs_services_by_county} -\title{aqs_services_by_county} -\usage{ -aqs_services_by_county( - parameter, - bdate, - edate, - stateFIPS, - countycode, - service, - duration = NA_character_, - cbdate = NA_Date_, - cedate = NA_Date_, - AQS_domain = "aqs.epa.gov" -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be -returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{service}{a string which represents the services provided by the AQS API -For a list of available services @seealso -\url{https://aqs.epa.gov/aqsweb/documents/data_api.html#services}} - -\item{duration}{an optional R character string that represents the -parameter duration code that limits returned data -to a specific sample duration. The default value of -NA_character_ results in no filtering based on -duration code.Valid durations include actual sample -durations and not calculated durations such as 8 -hour CO or $O_3$ rolling averages, 3/6 day PM -averages or Pb 3 month rolling averages. -@seealso \code{\link[=aqs_sampledurations]{aqs_sampledurations()}} for a list of all -available duration codes.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{AQS_domain}{a R string object containing the domain that should be -used in constructing the API call.} -} -\value{ -a AQS_DATAMART_APIv2 S3 object that is the return value from the -AQS API. A AQS_DATAMART_APIv2 is a 2 item named list in which the -first item ($Header) is a tibble of header information from the -AQS API and the second item ($Data) is a tibble of the data -returned. -} -\description{ -a helper function that abstracts the formatting of the inputs -for a call to aqs away from the calling function for -aggregations by county then calls the aqs and returns the -result. This helper function is not meant to be called -directly from external functions. -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_pqao.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_pqao.Rd deleted file mode 100644 index e65b2cf..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_pqao.Rd +++ /dev/null @@ -1,68 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/AQSAPI_helperfunctions.R -\name{aqs_services_by_pqao} -\alias{aqs_services_by_pqao} -\title{aqs_services_by_pqao} -\usage{ -aqs_services_by_pqao( - parameter, - bdate, - edate, - pqao_code, - service, - cbdate = NA_Date_, - cedate = NA_Date_, - AQS_domain = "aqs.epa.gov" -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{pqao_code}{a R character object which represents the 4 digit AQS -Primary Quality Assurance Organization code -(with leading zeroes).} - -\item{service}{a string which represents the services provided by the -AQS API. For a list of available services @seealso -\url{https://aqs.epa.gov/aqsweb/documents/data_api.html#services}} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{AQS_domain}{a R string object containing the domain that should be -used in constructing the API call.} -} -\value{ -a AQS_DATAMART_APIv2 S3 object that is the return value from the -AQS API. A AQS_DATAMART_APIv2 is a 2 item named list in which the -first item ($Header) is a tibble of header information from the -AQS API and the second item ($Data) is a tibble of the data -returned. -} -\description{ -a helper function that abstracts the formatting of the inputs -for a call to aqs away from the calling function for -aggregations by Primary Quality Assurance Organization (pqao) -then calls the aqs and returns the result. -This helper function is not meant to be called directly from -external functions. -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_site.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_site.Rd deleted file mode 100644 index d4a1933..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_site.Rd +++ /dev/null @@ -1,109 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/AQSAPI_helperfunctions.R -\name{aqs_services_by_site} -\alias{aqs_services_by_site} -\title{aqs_services_by_site} -\usage{ -aqs_services_by_site( - parameter, - bdate, - edate, - stateFIPS, - countycode, - sitenum, - duration = NA_character_, - service, - cbdate = NA_Date_, - cedate = NA_Date_, - AQS_domain = "aqs.epa.gov" -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{sitenum}{a R character object which represents the 4 digit site number -(with leading zeros) within the county and state being -requested.} - -\item{duration}{an optional R character string that represents the -parameter duration code that limits returned data -to a specific sample duration. The default value of -NA_character_ results in no filtering based on -duration code.Valid durations include actual sample -durations and not calculated durations such as 8 -hour CO or $O_3$ rolling averages, 3/6 day PM -averages or Pb 3 month rolling averages. -@seealso \code{\link[=aqs_sampledurations]{aqs_sampledurations()}} for a list of all -available duration codes.} - -\item{service}{a string which represents the services provided by the AQS -API. For a list of available services @seealso -\url{https://aqs.epa.gov/aqsweb/documents/data_api.html#services}} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{AQS_domain}{a R string object containing the domain that should be -used in constructing the API call.} -} -\value{ -a AQS_DATAMART_APIv2 S3 object that is the return value from the -AQS API. A AQS_DATAMART_APIv2 is a 2 item named list in which the -first item ($Header) is a tibble of header information from the -AQS API and the second item ($Data) is a tibble of the data -returned. -} -\description{ -a helper function that abstracts the formatting of the inputs -for a call to aqs away from the calling function for -aggregations by site then calls the aqs and returns the -result. This helper function is not meant to be called -directly from external functions. -} -\seealso{ -Other Aggregate _by_site functions: -\code{\link{aqs_annualsummary_by_site}()}, -\code{\link{aqs_dailysummary_by_site}()}, -\code{\link{aqs_monitors_by_site}()}, -\code{\link{aqs_qa_annualperformanceeval_by_site}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_county}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_site}()}, -\code{\link{aqs_qa_blanks_by_site}()}, -\code{\link{aqs_qa_collocated_assessments_by_site}()}, -\code{\link{aqs_qa_flowrateaudit_by_site}()}, -\code{\link{aqs_qa_flowrateverification_by_site}()}, -\code{\link{aqs_qa_one_point_qc_by_site}()}, -\code{\link{aqs_qa_pep_audit_by_site}()}, -\code{\link{aqs_sampledata_by_site}()}, -\code{\link{aqs_transactionsample_by_site}()} -} -\concept{Aggregate _by_site functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_state.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_state.Rd deleted file mode 100644 index f52cfde..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_services_by_state.Rd +++ /dev/null @@ -1,80 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/AQSAPI_helperfunctions.R -\name{aqs_services_by_state} -\alias{aqs_services_by_state} -\title{aqs_services_by_state} -\usage{ -aqs_services_by_state( - parameter, - bdate, - edate, - stateFIPS, - duration = NA_character_, - service, - cbdate = NA_Date_, - cedate = NA_Date_, - AQS_domain = "aqs.epa.gov" -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{duration}{an optional R character string that represents the -parameter duration code that limits returned data -to a specific sample duration. The default value of -NA_character_ results in no filtering based on -duration code.Valid durations include actual sample -durations and not calculated durations such as 8 -hour CO or $O_3$ rolling averages, 3/6 day PM -averages or Pb 3 month rolling averages. -@seealso \code{\link[=aqs_sampledurations]{aqs_sampledurations()}} for a list of all -available duration codes.} - -\item{service}{a string which represents the services provided by the -AQS API. For a list of available services @seealso -\url{https://aqs.epa.gov/aqsweb/documents/data_api.html#services}} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{AQS_domain}{a R string object containing the domain that should be -used in constructing the API call.} -} -\value{ -a AQS_DATAMART_APIv2 S3 object that is the return value from the -AQS API. A AQS_DATAMART_APIv2 is a 2 item named list in which the -first item ($Header) is a tibble of header information from the -AQS API and the second item ($Data) is a tibble of the data -returned. -} -\description{ -a helper function that abstracts the formatting of the inputs -for a call to aqs away from the calling function for -aggregations by State then calls the aqs and returns the -result. This helper function is not meant to be called -directly from external functions. -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sign_up.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sign_up.Rd deleted file mode 100644 index 82f96d8..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sign_up.Rd +++ /dev/null @@ -1,41 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/setupfunctions.R -\name{aqs_sign_up} -\alias{aqs_sign_up} -\title{aqs_sign_up} -\usage{ -aqs_sign_up(email) -} -\arguments{ -\item{email}{a R character object which represents the email account that -will be used to register with the AQS API or change an -existing user's key. A verification email will be sent to -the account specified. Follow the instructions -in the verification e-mail before proceeding to use any other -functionality of the AQS API. Register your credential -with the @3 \code{\link[=aqs_credentials]{aqs_credentials()}} before using the -other functions in this library.} -} -\value{ -None -} -\description{ -\lifecycle{stable} -Use this service to register as a new user or to reset an -existing user's key. A verification email will be sent to the -email account specified. To reset a password: If the request is -made with an email that is already registered, a new key will -be issued for that account and emailed to the listed address. -Usage is the same in either case. Refer to the email -message for further instructions before continuing. -} -\note{ -The '@' character needs to be escaped with the '/' character. -} -\examples{ -# to register a new user or generate a new key with the email - # address "John.Doe/@myemail.com" - \dontrun{aqs_sign_up(email = "John.Doe/@myemail.com")} - # after calling this function please follow the instructions that - # are sent in the verification e-mail before proceeding. -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sites_by_county.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sites_by_county.Rd deleted file mode 100644 index c8f097f..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_sites_by_county.Rd +++ /dev/null @@ -1,41 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/RAQSAPIlistfunctions.R -\name{aqs_sites_by_county} -\alias{aqs_sites_by_county} -\title{aqs_sites_by_county} -\usage{ -aqs_sites_by_county(stateFIPS, countycode, return_header = FALSE) -} -\arguments{ -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object of all air monitoring -sites with the requested state and county FIPS codes. -} -\description{ -\lifecycle{stable} -Returns data containing a table of all air monitoring sites -with the input state and county FIPS code combination. -} -\examples{ -# Returns an AQS_Data Mart_APIv2 S3 object witch returns all sites - # in Hawaii County, HI - \dontrun{aqs_sites_by_county(stateFIPS = "15", - countycode = "001") - } -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_states.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_states.Rd deleted file mode 100644 index 7c7abb3..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_states.Rd +++ /dev/null @@ -1,28 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/RAQSAPIlistfunctions.R -\name{aqs_states} -\alias{aqs_states} -\title{aqs_states} -\usage{ -aqs_states(return_header = FALSE) -} -\arguments{ -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns an AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object of states and their -associated FIPS codes. -} -\description{ -\lifecycle{stable} -Returns a table of US states, US territories, and the -district or Columbia with their respective FIPS codes. -} -\examples{ -# Returns a tibble of states and their FIPS codes - \dontrun{aqs_states()} -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_transactionsample_by_MA.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_transactionsample_by_MA.Rd deleted file mode 100644 index ee41d07..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_transactionsample_by_MA.Rd +++ /dev/null @@ -1,100 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/byma.R -\name{aqs_transactionsample_by_MA} -\alias{aqs_transactionsample_by_MA} -\title{aqs_transactionsample_MA} -\usage{ -aqs_transactionsample_by_MA( - parameter, - bdate, - edate, - MA_code, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be -returned.} - -\item{MA_code}{a R character object which represents the 4 digit AQS -Monitoring Agency code (with leading zeroes).} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object of transaction sample -(raw) data in the AQS submission transaction format (RD) -corresponding to the inputs provided. -} -\description{ -\lifecycle{stable} -Returns transactionsample data - aggregated by Monitoring agency (MA) -in the AQS Submission Transaction Format (RD) sample (raw) data for -a parameter code aggregated by matching input parameter, and -monitoring agency (MA) code provided for bdate - edate time -frame. Includes data both in submitted and standard units -} -\note{ -The AQS API only allows for a single year of transaction data to be -retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of -data at a time. Each calendar year of data requires a separate API -call so multiple years of data will require multiple API calls. -As the number of years of data being requested increases so does the -length of time that it will take to retrieve results. There is also a -5 second wait time inserted between successive API calls to prevent -overloading the API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -#Returns a tibble of ozone transaction sample data for all monitors - #operated by South Coast Air Quality Management District collected - #on May 15, 2015 - \dontrun{aqs_transactionsample_by_MA(parameter = "44201", - bdate = as.Date("20150515", - format = "\%Y\%m\%d"), - edate = as.Date("20150515", - format = "\%Y\%m\%d"), - MA_code = "0972" - ) - } -} -\seealso{ -Other Aggregate _by_state functions: -\code{\link{aqs_qa_annualperformanceeval_by_state}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_state}()}, -\code{\link{aqs_quarterlysummary_by_box}()}, -\code{\link{aqs_quarterlysummary_by_cbsa}()}, -\code{\link{aqs_quarterlysummary_by_state}()}, -\code{\link{aqs_transactionsample_by_state}()} -} -\concept{Aggregate _by_state functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_transactionsample_by_county.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_transactionsample_by_county.Rd deleted file mode 100644 index ee887ce..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_transactionsample_by_county.Rd +++ /dev/null @@ -1,99 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bycounty.R -\name{aqs_transactionsample_by_county} -\alias{aqs_transactionsample_by_county} -\title{aqs_transactionsample_by_county} -\usage{ -aqs_transactionsample_by_county( - parameter, - bdate, - edate, - stateFIPS, - countycode, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be -returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object of transaction sample -(raw) data in the AQS submission transaction format (RD) -corresponding to the inputs provided. -} -\description{ -\lifecycle{stable} -Returns transactionsample data - aggregated by county -in the AQS Submission Transaction Format (RD) sample (raw) data -for a parameter code aggregated by matching input parameter, -stateFIPS and countycode provided for bdate - edate time frame. -Includes data both in submitted and standard units -} -\note{ -The AQS API only allows for a single year of transaction data to be -retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of -data at a time. Each calendar year of data requires a separate API -call so multiple years of data will require multiple API calls. -As the number of years of data being requested increases so does the -length of time that it will take to retrieve results. There is also a -5 second wait time inserted between successive API calls to prevent -overloading the API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ - \dontrun{ # Returns all FRM/FEM transaction data for - # Wake County, NC between on Feb 28, 2016. - aqs_transactionsample_by_county(parameter = "88101", - bdate = as.Date("20160228", - format = "\%Y\%m\%d"), - edate = as.Date("20160228", - format = "\%Y\%m\%d"), - stateFIPS = "37", - countycode = "183" - ) - } -} -\seealso{ -Other Aggregate _by_county functions: -\code{\link{aqs_annualsummary_by_county}()}, -\code{\link{aqs_dailysummary_by_county}()}, -\code{\link{aqs_monitors_by_county}()}, -\code{\link{aqs_qa_annualperformanceeval_by_county}()}, -\code{\link{aqs_qa_blanks_by_county}()}, -\code{\link{aqs_qa_collocated_assessments_by_county}()}, -\code{\link{aqs_qa_flowrateaudit_by_county}()}, -\code{\link{aqs_qa_flowrateverification_by_county}()}, -\code{\link{aqs_qa_one_point_qc_by_county}()}, -\code{\link{aqs_qa_pep_audit_by_county}()}, -\code{\link{aqs_quarterlysummary_by_county}()}, -\code{\link{aqs_quarterlysummary_by_site}()}, -\code{\link{aqs_sampledata_by_county}()} -} -\concept{Aggregate _by_county functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_transactionsample_by_site.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_transactionsample_by_site.Rd deleted file mode 100644 index 8de54aa..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_transactionsample_by_site.Rd +++ /dev/null @@ -1,123 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bysite.R -\name{aqs_transactionsample_by_site} -\alias{aqs_transactionsample_by_site} -\title{aqs_transactionsample_by_site} -\usage{ -aqs_transactionsample_by_site( - parameter, - bdate, - edate, - stateFIPS, - countycode, - sitenum, - cbdate = NA_Date_, - cedate = NA_Date_, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{countycode}{a R character object which represents the 3 digit state -FIPS code for the county being requested (with leading -zero(s)). @seealso \code{\link[=aqs_counties_by_state]{aqs_counties_by_state()}} for the -list of available county codes for each state.} - -\item{sitenum}{a R character object which represents the 4 digit site number -(with leading zeros) within the county and state being -requested.} - -\item{cbdate}{a R date object which represents a "beginning -date of last change" that indicates when the data was last -updated. cbdate is used to filter data based on the change -date. Only data that changed on or after this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{cedate}{a R date object which represents an "end -date of last change" that indicates when the data was last -updated. cedate is used to filter data based on the change -date. Only data that changed on or before this date will be -returned. This is an optional variable which defaults -to NA_Date_.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object of transaction sample -(raw) data in the AQS submission transaction format (RD) -corresponding to the inputs provided. -} -\description{ -\lifecycle{stable} -Returns transactionsample data aggregated by site -in the AQS Submission Transaction Format (RD) sample (raw) data for -a parameter code aggregated by matching input parameter, sitenum, -countycode and stateFIPS provided for bdate - edate time frame. -Includes data both in submitted and standard units -} -\note{ -The AQS API only allows for a single year of transaction data to be -retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of -data at a time. Each calendar year of data requires a separate API -call so multiple years of data will require multiple API calls. -As the number of years of data being requested increases so does the -length of time that it will take to retrieve results. There is also a -5 second wait time inserted between successive API calls to prevent -overloading the API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -#Returns a AQS_Data Mart_APIv2 S3 object of the returns - \dontrun{ # returns all ozone transaction data for the - # Millbrook School site (#0014) in Wake County, NC for - # June 18, 2017 - aqs_transactionsample_by_site(parameter = "44201", - bdate = as.Date("20170618", - format = "\%Y\%m\%d"), - edate = as.Date("20170618", - format = "\%Y\%m\%d"), - stateFIPS = "37", - countycode = "183", - sitenum = "0014" - ) - } -} -\seealso{ -Other Aggregate _by_site functions: -\code{\link{aqs_annualsummary_by_site}()}, -\code{\link{aqs_dailysummary_by_site}()}, -\code{\link{aqs_monitors_by_site}()}, -\code{\link{aqs_qa_annualperformanceeval_by_site}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_county}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_site}()}, -\code{\link{aqs_qa_blanks_by_site}()}, -\code{\link{aqs_qa_collocated_assessments_by_site}()}, -\code{\link{aqs_qa_flowrateaudit_by_site}()}, -\code{\link{aqs_qa_flowrateverification_by_site}()}, -\code{\link{aqs_qa_one_point_qc_by_site}()}, -\code{\link{aqs_qa_pep_audit_by_site}()}, -\code{\link{aqs_sampledata_by_site}()}, -\code{\link{aqs_services_by_site}()} -} -\concept{Aggregate _by_site functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_transactionsample_by_state.Rd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_transactionsample_by_state.Rd deleted file mode 100644 index 9a4691b..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/aqs_transactionsample_by_state.Rd +++ /dev/null @@ -1,85 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/bystate.R -\name{aqs_transactionsample_by_state} -\alias{aqs_transactionsample_by_state} -\title{aqs_transactionsample_by_state} -\usage{ -aqs_transactionsample_by_state( - parameter, - bdate, - edate, - stateFIPS, - return_header = FALSE -) -} -\arguments{ -\item{parameter}{a character list or a single character string -which represents the parameter code of the air -pollutant related to the data being requested.} - -\item{bdate}{a R date object which represents that begin date of the data -selection. Only data on or after this date will be returned.} - -\item{edate}{a R date object which represents that end date of the data -selection. Only data on or before this date will be returned.} - -\item{stateFIPS}{a R character object which represents the 2 digit state -FIPS code (with leading zero) for the state being -requested. @seealso \code{\link[=aqs_states]{aqs_states()}} for the list of -available FIPS codes.} - -\item{return_header}{If FALSE (default) only returns data requested. -If TRUE returns a AQSAPI_v2 object which is a two -item list that contains header information returned -from the API server mostly used for debugging -purposes in addition to the data requested.} -} -\value{ -a tibble or an AQS_Data Mart_APIv2 S3 object of transaction sample -(raw) data in the AQS submission transaction format (RD) -corresponding to the inputs provided. -} -\description{ -\lifecycle{stable} -Returns transactionsample data - aggregated by state -in the AQS Submission Transaction Format (RD) sample (raw) data for -a parameter code aggregated by matching input parameter, and -stateFIPS provided for bdate - edate time frame. Includes data both -in submitted and standard units -} -\note{ -The AQS API only allows for a single year of transaction data to be -retrieved at a time. This function conveniently extracts date -information from the bdate and edate parameters then makes repeated -calls to the AQSAPI retrieving a maximum of one calendar year of -data at a time. Each calendar year of data requires a separate API -call so multiple years of data will require multiple API calls. -As the number of years of data being requested increases so does the -length of time that it will take to retrieve results. There is also a -5 second wait time inserted between successive API calls to prevent -overloading the API server. This operation has a linear run time of -/(Big O notation: O/(n + 5 seconds/)/). -} -\examples{ -#Returns a AQS_Data Mart_APIv2 S3 object of - \dontrun{ # Returns a tibble containing benzene transaction sample - # data for North Carolina on May 15, 1995 - aqs_transactionsample_by_state(parameter = "45201", - bdate = as.Date("19950515", - format = "\%Y\%m\%d"), - edate = as.Date("19950515", - format = "\%Y\%m\%d"), - stateFIPS = "37" - ) - } -} -\seealso{ -Other Aggregate _by_state functions: -\code{\link{aqs_qa_annualperformanceeval_by_state}()}, -\code{\link{aqs_qa_annualperformanceevaltransaction_by_state}()}, -\code{\link{aqs_quarterlysummary_by_box}()}, -\code{\link{aqs_quarterlysummary_by_cbsa}()}, -\code{\link{aqs_quarterlysummary_by_state}()}, -\code{\link{aqs_transactionsample_by_MA}()} -} -\concept{Aggregate _by_state functions} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-archived.svg b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-archived.svg deleted file mode 100644 index 745ab0c..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-archived.svg +++ /dev/null @@ -1,21 +0,0 @@ - - lifecycle: archived - - - - - - - - - - - - - - - lifecycle - - archived - - diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-defunct.svg b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-defunct.svg deleted file mode 100644 index d5c9559..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-defunct.svg +++ /dev/null @@ -1,21 +0,0 @@ - - lifecycle: defunct - - - - - - - - - - - - - - - lifecycle - - defunct - - diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-deprecated.svg b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-deprecated.svg deleted file mode 100644 index b61c57c..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-deprecated.svg +++ /dev/null @@ -1,21 +0,0 @@ - - lifecycle: deprecated - - - - - - - - - - - - - - - lifecycle - - deprecated - - diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-experimental.svg b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-experimental.svg deleted file mode 100644 index 5d88fc2..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-experimental.svg +++ /dev/null @@ -1,21 +0,0 @@ - - lifecycle: experimental - - - - - - - - - - - - - - - lifecycle - - experimental - - diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-maturing.svg b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-maturing.svg deleted file mode 100644 index 897370e..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-maturing.svg +++ /dev/null @@ -1,21 +0,0 @@ - - lifecycle: maturing - - - - - - - - - - - - - - - lifecycle - - maturing - - diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-questioning.svg b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-questioning.svg deleted file mode 100644 index 7c1721d..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-questioning.svg +++ /dev/null @@ -1,21 +0,0 @@ - - lifecycle: questioning - - - - - - - - - - - - - - - lifecycle - - questioning - - diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-soft-deprecated.svg b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-soft-deprecated.svg deleted file mode 100644 index 9c166ff..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-soft-deprecated.svg +++ /dev/null @@ -1,21 +0,0 @@ - - lifecycle: soft-deprecated - - - - - - - - - - - - - - - lifecycle - - soft-deprecated - - diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-stable.svg b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-stable.svg deleted file mode 100644 index 9bf21e7..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-stable.svg +++ /dev/null @@ -1,29 +0,0 @@ - - lifecycle: stable - - - - - - - - - - - - - - - - lifecycle - - - - stable - - - diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-superseded.svg b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-superseded.svg deleted file mode 100644 index db8d757..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/man/figures/lifecycle-superseded.svg +++ /dev/null @@ -1,21 +0,0 @@ - - lifecycle: superseded - - - - - - - - - - - - - - - lifecycle - - superseded - - diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/spelling.R b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/spelling.R deleted file mode 100644 index 33ef2c7..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/spelling.R +++ /dev/null @@ -1,3 +0,0 @@ -if (requireNamespace("spelling", quietly = TRUE)) - spelling::spell_check_test(vignettes = TRUE, error = FALSE, - skip_on_cran = TRUE) diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/test-RAQSAPI.R.blob b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/test-RAQSAPI.R.blob deleted file mode 100644 index b1b7d93..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/test-RAQSAPI.R.blob +++ /dev/null @@ -1,59 +0,0 @@ -test_that("Checking for AQSDatamartAPI credentials keyring", { -"AQSDatamartAPI" %>% - str_detect(keyring::key_list()$service) %>% - any() %>% - expect_true() -} - -context("testing connection to AQS Datamart API") -test_that("Checking status of AQS Datmart API", { -import::here(.from = "magrittr", "%>%") -AQS_API_isAvailable()$status %>% - str_detect("API service is up and running healthy") %>% - expect_true -} - -context("running AQS API calls to look for errors being returned") -test_that("checking that functions return proper data type", { -states <- AQS_API_states() %>% expect_s3_class(class="AQS_API") -isavailable <- AQS_API_isAvailable() expect_true -counties <- AQS_API_countiesByState(stateFIPS = "42") %>% expect_s3_class(class="AQS_API") -sites <- AQS_API_sitesByCounty(stateFIPS = "42", countycode = "101") %>% expect_s3_class(class="AQS_API") -cbsas <- AQS_API_cbsas() %>% expect_s3_class(class="AQS_API") -classes <- AQS_API_classes() %>% expect_s3_class(class="AQS_API") -pbc <- AQS_API_parametersByClass(class = "CRITERIA") %>% expect_s3_class(class="AQS_API") -mas <- AQS_API_monitoringagencies() %>% expect_s3_class(class="AQS_API") -PQAOs <- AQS_API_PQAO() %>% expect_s3_class(class="AQS_API") -fbs <- AQS_API_fieldByService(service = "sampleData") %>% expect_s3_class(class="AQS_API") -mbs <- AQS_API_monitorsbysite(parameter = "44201", - bdate = ymd("2019-01-01"), - edate = mdy("03-31-2019"), - stateFIPS = "42", - countycode = "003", - sitenum = "0008" - ) %>% - expect_s3_class(class="AQS_API") - -mbc <- AQS_API_monitorsbycounty(parameter = "44201", - bdate = ymd("2019-01-01"), - edate = mdy("03-31-2019"), - stateFIPS = "42", - countycode = "003" - ) %>% - expect_s3_class(class="AQS_API") - -mbstate <- AQS_API_monitorsbystate(parameter = "44201", - bdate = ymd("2019-01-01"), - edate = mdy("03-31-2019"), - stateFIPS = "42" - ) %>% - expect_s3_class(class="AQS_API") -} - -context("ensuring that code properly check for invalid input") -test_that("checking invalid input", { -pby <- AQS_API_parametersByClass(class = "taco") %>% expect_null -counties <- AQS_API_countiesByState(stateFIPS = "ZZ9") %>% expect_null -sites <- AQS_API_sitesByCounty(stateFIPS = "42", countycode = "9999") %>% expect_null - -} \ No newline at end of file diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat.R b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat.R deleted file mode 100644 index 2782837..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat.R +++ /dev/null @@ -1,4 +0,0 @@ -library(testthat) -library(RAQSAPI) - -test_check("RAQSAPI") diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/helper.R b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/helper.R deleted file mode 100644 index c984b9d..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/helper.R +++ /dev/null @@ -1,17 +0,0 @@ -RAQSAPItestsetup_helper <- function() -{ - path <- NA - if(file.exists("local.R")) {path <- "./"} - else if(file.exists("tests/testthat/local.R")) {path <- "tests/testthat/"} - - if(!is.na(path)) - { - source(paste0(path, "local.R")) - AQScredentials <- RAQSAPItestsetup_local() - datamartAPI_user <- AQScredentials$AQSusername - datamartAPI_key <- AQScredentials$AQSkey - AQScredentials <- list(datamartAPI_user = datamartAPI_user, - datamartAPI_key = datamartAPI_key) - return(AQScredentials) - } else {print("did not go into if satement")} #debug -} diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-RAQSAPlistfunctions.R b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-RAQSAPlistfunctions.R deleted file mode 100644 index 98489b0..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-RAQSAPlistfunctions.R +++ /dev/null @@ -1,65 +0,0 @@ -#' @importFrom magrittr `%>%`() -#' @import testthat -#' @importFrom magrittr `%>%`() -#' @import testthat - -test_that("test list functions", { - testthat::skip_on_cran() - testthat::skip_if_offline() - - if(file.exists("local.R")) - { - source("helper.R") - AQScredentials <- RAQSAPItestsetup_helper() - datamartAPI_user <- AQScredentials$datamartAPI_user - datamartAPI_key <- AQScredentials$datamartAPI_key - } else { - datamartAPI_user <- Sys.getenv("RAQSAPIKEY", names = TRUE) - datamartAPI_key <- Sys.getenv("RAQSAPIUSERNAME", names = TRUE) - } - RAQSAPI::aqs_credentials(username = datamartAPI_user, - key = datamartAPI_key - ) - - aqs_isavailable(return_header = TRUE)$Header$status %>% - expect_match(regexp = "API service is up and running healthy", - fixed = FALSE - ) - - aqs_fields_by_service(service = "list", - return_header = TRUE)$Header$status %>% - expect_match(regexp = "Success") - - aqs_knownissues(return_header = TRUE)$Header$status %>% - expect_match(regexp = "Success") - - aqs_revisionhistory(return_header = TRUE)$Header$status %>% - expect_match(regexp = "Success") - - aqs_states(return_header = TRUE)$Header$status %>% - expect_match(regexp = "Success") - - aqs_counties_by_state(stateFIPS = "40", - return_header = TRUE - )$Header$status %>% - expect_match(regexp = "Success") - - aqs_pqaos(return_header = TRUE)$Header$status %>% - expect_match(regexp = "Success") - - aqs_cbsas(return_header = TRUE)$Header$status %>% - expect_match(regexp = "Success") - - aqs_classes(return_header = TRUE)$Header$status %>% - expect_match(regexp = "Success") - - aqs_sites_by_county(stateFIPS = "15", - countycode = "001", - return_header = TRUE)$Header$status %>% - expect_match(regexp = "Success") - - aqs_parameters_by_class(class = "CRITERIA", - return_header = TRUE)$Header$status %>% - expect_match(regexp = "Success") - -}) diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-byCBSA.R b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-byCBSA.R deleted file mode 100644 index e5f9b29..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-byCBSA.R +++ /dev/null @@ -1,63 +0,0 @@ -#' @importFrom magrittr `%>%`() -#' @import testthat -test_that("bybox functions", { - testthat::skip_on_cran() - testthat::skip_if_offline() - - if(file.exists("local.R")) - { - source("helper.R") - AQScredentials <- RAQSAPItestsetup_helper() - datamartAPI_user <- AQScredentials$datamartAPI_user - datamartAPI_key <- AQScredentials$datamartAPI_key - } else { - datamartAPI_user <- Sys.getenv("RAQSAPIKEY", names = TRUE) - datamartAPI_key <- Sys.getenv("RAQSAPIUSERNAME", names = TRUE) - } - RAQSAPI::aqs_credentials(username = datamartAPI_user, - key = datamartAPI_key - ) - - aqs_monitors_by_cbsa(parameter = "42602", - bdate = as.Date("20170101", format = "%Y%m%d"), - edate = as.Date("20170102", format = "%Y%m%d"), - cbsa_code = "16740", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_annualsummary_by_cbsa(parameter = "42602", - bdate = as.Date("20170101", format = "%Y%m%d"), - edate = as.Date("20170101", format = "%Y%m%d"), - cbsa_code = "16740", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_dailysummary_by_cbsa(parameter = "42602", - bdate = as.Date("20170101", format = "%Y%m%d"), - edate = as.Date("20170101", format = "%Y%m%d"), - cbsa_code = "16740", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_sampledata_by_cbsa(parameter = "42602", - bdate = as.Date("20170101", format = "%Y%m%d"), - edate = as.Date("20170101", format = "%Y%m%d"), - cbsa_code = "16740", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_quarterlysummary_by_cbsa(parameter = "42602", - bdate = as.Date("20170101", format = "%Y%m%d"), - edate = as.Date("20171231", format = "%Y%m%d"), - cbsa_code = "16740", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_sampledurations(return_header = TRUE)$Header$status %>% - expect_match(regexp = "Success") -}) diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-byMA.R b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-byMA.R deleted file mode 100644 index 47cb27e..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-byMA.R +++ /dev/null @@ -1,100 +0,0 @@ -#' @importFrom magrittr `%>%`() -#' @import testthat -test_that("byMA functions", { - testthat::skip_on_cran() - testthat::skip_if_offline() - - if(file.exists("local.R")) - { - source("helper.R") - AQScredentials <- RAQSAPItestsetup_helper() - datamartAPI_user <- AQScredentials$datamartAPI_user - datamartAPI_key <- AQScredentials$datamartAPI_key - } else { - datamartAPI_user <- Sys.getenv("RAQSAPIKEY", names = TRUE) - datamartAPI_key <- Sys.getenv("RAQSAPIUSERNAME", names = TRUE) - } - RAQSAPI::aqs_credentials(username = datamartAPI_user, - key = datamartAPI_key - ) - - aqs_qa_blanks_by_MA(parameter = "88101", - bdate = as.Date("20180101", format = "%Y%m%d"), - edate = as.Date("20180131", format = "%Y%m%d"), - MA_code = "0013", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_qa_collocated_assessments_by_MA(parameter = "88101", - bdate = as.Date("20130101", - format = "%Y%m%d"), - edate = as.Date("20130131", - format = "%Y%m%d"), - MA_code = "0013", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_qa_one_point_qc_by_MA(parameter = "44201", - bdate = as.Date("20180101", format = "%Y%m%d"), - edate = as.Date("20180131", format = "%Y%m%d"), - MA_code = "0660", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_qa_flowrateaudit_by_MA(parameter = "88101", - bdate = as.Date("20180101", format = "%Y%m%d"), - edate = as.Date("20180131", format = "%Y%m%d"), - MA_code = "0550", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_qa_flowrateverification_by_MA(parameter = "88101", - bdate = as.Date("20130101", - format = "%Y%m%d"), - edate = as.Date("20130131", - format = "%Y%m%d"), - MA_code = "0013", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_qa_pep_audit_by_MA(parameter = "88101", - bdate = as.Date("20170601", format = "%Y%m%d"), - edate = as.Date("20170630", format = "%Y%m%d"), - MA_code = "0013", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_transactionsample_by_MA(parameter = "44201", - bdate = as.Date("20150515", format = "%Y%m%d"), - edate = as.Date("20150515", format = "%Y%m%d"), - MA_code = "0972", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_qa_annualperformanceeval_by_MA(parameter = "44201", - bdate = as.Date("20170101", - format = "%Y%m%d"), - edate = as.Date("20171231", - format = "%Y%m%d"), - MA_code = "0013", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_qa_annualperformanceevaltransaction_by_MA(parameter = "44201", - bdate = as.Date("20170101", - format = "%Y%m%d"), - edate = as.Date("20171231", - format = "%Y%m%d"), - MA_code = "0013", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") -}) diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-bybox.R b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-bybox.R deleted file mode 100644 index efb50d9..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-bybox.R +++ /dev/null @@ -1,80 +0,0 @@ -#' @importFrom magrittr `%>%`() -#' @import testthat -test_that("bybox functions", { -testthat::skip_on_cran() -testthat::skip_if_offline() - - if(file.exists("local.R")) - { - source("helper.R") - AQScredentials <- RAQSAPItestsetup_helper() - datamartAPI_user <- AQScredentials$datamartAPI_user - datamartAPI_key <- AQScredentials$datamartAPI_key - } else { - datamartAPI_user <- Sys.getenv("RAQSAPIKEY", names = TRUE) - datamartAPI_key <- Sys.getenv("RAQSAPIUSERNAME", names = TRUE) - } - RAQSAPI::aqs_credentials(username = datamartAPI_user, - key = datamartAPI_key - ) - - RAQSAPI::aqs_isavailable(return_header = TRUE)$Header$status %>% - expect_match(regexp = "API service is up and running healthy", - fixed = FALSE - ) - - aqs_sampledata_by_box(parameter = "44201", - bdate = as.Date("20150501", format = "%Y%m%d"), - edate = as.Date("20150502", format = "%Y%m%d"), - minlat = "33.3", - maxlat = "33.6", - minlon = "-87.0", - maxlon = "-86.7", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_monitors_by_box(parameter = "44201", - bdate = as.Date("19950101", format = "%Y%m%d"), - edate = as.Date("19951231", format = "%Y%m%d"), - minlat = "33.3", - maxlat = "33.6", - minlon = "-87.0", - maxlon = "-86.7", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_annualsummary_by_box(parameter = "44201", - bdate = as.Date("20150501", format = "%Y%m%d"), - edate = as.Date("20150502", format = "%Y%m%d"), - minlat = "33.3", - maxlat = "33.6", - minlon = "-87.0", - maxlon = "-86.7", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_dailysummary_by_box(parameter = "44201", - bdate = as.Date("20150501", format = "%Y%m%d"), - edate = as.Date("20150502", format = "%Y%m%d"), - minlat = "33.3", - maxlat = "33.6", - minlon = "-87.0", - maxlon = "-86.7", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_quarterlysummary_by_box(parameter = "44201", - bdate = as.Date("20150101", format = "%Y%m%d"), - edate = as.Date("20171231", format = "%Y%m%d"), - minlat = "33.3", - maxlat = "33.6", - minlon = "-87.0", - maxlon = "-86.7", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") -}) diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-bycounty.R b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-bycounty.R deleted file mode 100644 index 74c8a7e..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-bycounty.R +++ /dev/null @@ -1,155 +0,0 @@ -#' @importFrom magrittr `%>%`() -#' @import testthat -test_that("bycounty functions", { - testthat::skip_on_cran() - testthat::skip_if_offline() - - if(file.exists("local.R")) - { - source("helper.R") - AQScredentials <- RAQSAPItestsetup_helper() - datamartAPI_user <- AQScredentials$datamartAPI_user - datamartAPI_key <- AQScredentials$datamartAPI_key - } else { - datamartAPI_user <- Sys.getenv("RAQSAPIKEY", names = TRUE) - datamartAPI_key <- Sys.getenv("RAQSAPIUSERNAME", names = TRUE) - } - RAQSAPI::aqs_credentials(username = datamartAPI_user, - key = datamartAPI_key - ) - - aqs_annualsummary_by_county(parameter = "88101", - bdate = as.Date("20160101", format = "%Y%m%d"), - edate = as.Date("20160228", format = "%Y%m%d"), - stateFIPS = "37", - countycode = "183", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_dailysummary_by_county(parameter = "88101", - bdate = as.Date("20160101", format = "%Y%m%d"), - edate = as.Date("20160228", format = "%Y%m%d"), - stateFIPS = "37", - countycode = "183", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_sampledata_by_county(parameter = "88101", - bdate = as.Date("20160101", - format = "%Y%m%d"), - edate = as.Date("20160101", - format = "%Y%m%d"), - stateFIPS = "37", - countycode = "183", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_monitors_by_county(parameter = "42401", - bdate = as.Date("20150501", format = "%Y%m%d"), - edate = as.Date("20150502", format = "%Y%m%d"), - stateFIPS = "15", - countycode = "001", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_qa_collocated_assessments_by_county(parameter = "88101", - bdate = as.Date("20150101", - format = "%Y%m%d"), - edate = as.Date("20150131", - format = "%Y%m%d"), - stateFIPS = "01", - countycode = "089", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_qa_blanks_by_county(parameter = "88101", - bdate = as.Date("20180101", format = "%Y%m%d"), - edate = as.Date("20180131", format = "%Y%m%d"), - stateFIPS = "01", - countycode = "033", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_qa_flowrateaudit_by_county(parameter = "88101", - bdate = as.Date("20180101", format = "%Y%m%d"), - edate = as.Date("20180131", format = "%Y%m%d"), - stateFIPS = "01", countycode = "073", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_qa_flowrateverification_by_county(parameter = "88101", - bdate = as.Date("20180101", - format = "%Y%m%d"), - edate = as.Date("20180131", - format = "%Y%m%d"), - stateFIPS = "01", - countycode = "033", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_qa_one_point_qc_by_county(parameter = "44201", - bdate = as.Date("20180101", format = "%Y%m%d"), - edate = as.Date("20180131", format = "%Y%m%d"), - stateFIPS = "25", - countycode = "001", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_qa_pep_audit_by_county(parameter = "88101", - bdate = as.Date("20170101", format = "%Y%m%d"), - edate = as.Date("20171231", format = "%Y%m%d"), - stateFIPS = "01", - countycode = "089", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_transactionsample_by_county(parameter = "88101", - bdate = as.Date("20160228", format = "%Y%m%d"), - edate = as.Date("20160228", format = "%Y%m%d"), - stateFIPS = "37", - countycode = "183", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_qa_annualperformanceeval_by_county(parameter = "44201", - bdate = as.Date("20170101", - format = "%Y%m%d"), - edate = as.Date("20171231", - format = "%Y%m%d"), - stateFIPS = "01", - countycode = "003", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_qa_annualperformanceevaltransaction_by_county(parameter = "44201", - bdate = as.Date("20170101", - format = "%Y%m%d"), - edate = as.Date("20171231", - format = "%Y%m%d"), - stateFIPS = "01", - countycode = "003", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_quarterlysummary_by_county(parameter = "88101", - bdate = as.Date("20160101", format = "%Y%m%d"), - edate = as.Date("20170228", format = "%Y%m%d"), - stateFIPS = "37", - countycode = "183", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") -}) diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-bypqao.R b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-bypqao.R deleted file mode 100644 index 352469f..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-bypqao.R +++ /dev/null @@ -1,103 +0,0 @@ -#' @importFrom magrittr `%>%`() -#' @import testthat -test_that("bypqao functions", { - testthat::skip_on_cran() - testthat::skip_if_offline() - - if(file.exists("local.R")) - { - source("helper.R") - AQScredentials <- RAQSAPItestsetup_helper() - datamartAPI_user <- AQScredentials$datamartAPI_user - datamartAPI_key <- AQScredentials$datamartAPI_key - } else { - datamartAPI_user <- Sys.getenv("RAQSAPIKEY", names = TRUE) - datamartAPI_key <- Sys.getenv("RAQSAPIUSERNAME", names = TRUE) - } - RAQSAPI::aqs_credentials(username = datamartAPI_user, - key = datamartAPI_key - ) - - aqs_qa_blanks_by_pqao(parameter = "88101", - bdate = as.Date("20180101", format = "%Y%m%d"), - edate = as.Date("20180131", format = "%Y%m%d"), - pqao_code = "0013", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_qa_collocated_assessments_by_pqao(parameter = "88101", - bdate = as.Date("20130101", - format = "%Y%m%d"), - edate = as.Date("20130131", - format = "%Y%m%d"), - pqao_code = "0013", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_qa_flowrateaudit_by_pqao(parameter = "88101", - bdate = as.Date("20180101", format = "%Y%m%d"), - edate = as.Date("20180131", format = "%Y%m%d"), - pqao_code = "0550", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_qa_flowrateverification_by_pqao(parameter = "88101", - bdate = as.Date("20180101", - format = "%Y%m%d"), - edate = as.Date("20180131", - format = "%Y%m%d"), - pqao_code = "0013", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_qa_one_point_qc_by_pqao(parameter = "44201", - bdate = as.Date("20180101", format = "%Y%m%d"), - edate = as.Date("20180131", format = "%Y%m%d"), - pqao_code = "0660", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_qa_pep_audit_by_pqao(parameter = "88101", - bdate = as.Date("20170601", format = "%Y%m%d"), - edate = as.Date("20170630", format = "%Y%m%d"), - pqao_code = "0013", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_qa_collocated_assessments_by_pqao(parameter = "88101", - bdate = as.Date("20130101", - format = "%Y%m%d"), - edate = as.Date("20130131", - format = "%Y%m%d"), - pqao_code = "0013", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_qa_annualperformanceeval_by_pqao(parameter = "44201", - bdate = as.Date("20170101", - format = "%Y%m%d"), - edate = as.Date("20171231", - format = "%Y%m%d"), - pqao_code = "0013", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_qa_annualperformanceevaltransaction_by_pqao(parameter = "44201", - bdate = as.Date("20170101", - format = "%Y%m%d"), - edate = as.Date("20171231", - format = "%Y%m%d"), - pqao_code = "0013", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -}) diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-bysite.R b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-bysite.R deleted file mode 100644 index 9f2c556..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-bysite.R +++ /dev/null @@ -1,175 +0,0 @@ -#' @importFrom magrittr `%>%`() -#' @import testthat -test_that("bysite functions", { - testthat::skip_on_cran() - testthat::skip_if_offline() - - if(file.exists("local.R")) - { - source("helper.R") - AQScredentials <- RAQSAPItestsetup_helper() - datamartAPI_user <- AQScredentials$datamartAPI_user - datamartAPI_key <- AQScredentials$datamartAPI_key - } else { - datamartAPI_user <- Sys.getenv("RAQSAPIKEY", names = TRUE) - datamartAPI_key <- Sys.getenv("RAQSAPIUSERNAME", names = TRUE) - } - RAQSAPI::aqs_credentials(username = datamartAPI_user, - key = datamartAPI_key - ) - - RAQSAPI::aqs_sampledata_by_site(parameter = "44201", - bdate = as.Date("20170618", - format = "%Y%m%d"), - edate = as.Date("20170618", - format = "%Y%m%d"), - stateFIPS = "37", - countycode = "183", - sitenum = "0014", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_annualsummary_by_site(parameter = "44201", - bdate = as.Date("20170618", format = "%Y%m%d"), - edate = as.Date("20170618", format = "%Y%m%d"), - stateFIPS = "37", - countycode = "183", - sitenum = "0014", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_dailysummary_by_site(parameter = "44201", - bdate = as.Date("20170618", format = "%Y%m%d"), - edate = as.Date("20170618", format = "%Y%m%d"), - stateFIPS = "37", - countycode = "183", - sitenum = "0014", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_qa_blanks_by_site(parameter = "88101", - bdate = as.Date("20180101", format = "%Y%m%d"), - edate = as.Date("20180131", format = "%Y%m%d"), - stateFIPS = "01", - countycode = "033", - sitenum = "1002", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_monitors_by_site(parameter = "42401", - bdate = as.Date("20150501", format = "%Y%m%d"), - edate = as.Date("20190501", format = "%Y%m%d"), - stateFIPS = "15", - countycode = "001", - sitenum = "0007", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_qa_collocated_assessments_by_site(parameter = "88101", - bdate = as.Date("20150101", - format = "%Y%m%d"), - edate = as.Date("20150131", - format = "%Y%m%d"), - stateFIPS = "01", - countycode = "089", - sitenum = "0014", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_qa_flowrateaudit_by_site(parameter = "88101", - bdate = as.Date("20180101", - format = "%Y%m%d"), - edate = as.Date("20180131", - format = "%Y%m%d"), - stateFIPS = "01", - countycode = "073", - sitenum = "2003", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_qa_one_point_qc_by_site(parameter = "44201", - bdate = as.Date("20180101", - format = "%Y%m%d"), - edate = as.Date("20180131", - format = "%Y%m%d"), - stateFIPS = "25", - countycode = "001", - sitenum = "0002", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_qa_flowrateverification_by_site(parameter = "88101", - bdate = as.Date("20180101", - format = "%Y%m%d"), - edate = as.Date("20180131", - format = "%Y%m%d"), - stateFIPS = "01", - countycode = "033", - sitenum = "1002", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_transactionsample_by_site(parameter = "44201", - bdate = as.Date("20170618", format = "%Y%m%d"), - edate = as.Date("20170618", format = "%Y%m%d"), - stateFIPS = "37", - countycode = "183", - sitenum = "0014", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_qa_annualperformanceeval_by_site(parameter = "44201", - bdate = as.Date("20170101", - format = "%Y%m%d"), - edate = as.Date("20171231", - format = "%Y%m%d"), - stateFIPS = "01", - countycode = "003", - sitenum = "0010", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_qa_annualperformanceevaltransaction_by_site(parameter = "44201", - bdate = as.Date("20170101", - format = "%Y%m%d"), - edate = as.Date("20171231", - format = "%Y%m%d"), - stateFIPS = "01", - countycode = "003", - sitenum = "0010", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_quarterlysummary_by_site(parameter = "88101", - bdate = as.Date("20160101", format = "%Y%m%d"), - edate = as.Date("20160331", format = "%Y%m%d"), - stateFIPS = "37", - countycode = "183", - sitenum = "0014", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_qa_pep_audit_by_site(parameter = "88101", - bdate = as.Date("20170101", format = "%Y%m%d"), - edate = as.Date("20191231", format = "%Y%m%d"), - stateFIPS = "01", - countycode = "089", - sitenum = "0014", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -}) diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-bystate.R b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-bystate.R deleted file mode 100644 index a9a9383..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-bystate.R +++ /dev/null @@ -1,159 +0,0 @@ -#' @importFrom magrittr `%>%`() -#' @import testthat - -test_that("bystate functions", { - testthat::skip_on_cran() - testthat::skip_if_offline() - - if(file.exists("local.R")) - { - source("helper.R") - AQScredentials <- RAQSAPItestsetup_helper() - datamartAPI_user <- AQScredentials$datamartAPI_user - datamartAPI_key <- AQScredentials$datamartAPI_key - } else { - datamartAPI_user <- Sys.getenv("RAQSAPIKEY", names = TRUE) - datamartAPI_key <- Sys.getenv("RAQSAPIUSERNAME", names = TRUE) - } - RAQSAPI::aqs_credentials(username = datamartAPI_user, - key = datamartAPI_key - ) - -aqs_monitors_by_state(parameter = "88101", - bdate = as.Date("20170101", format = "%Y%m%d"), - edate = as.Date("20171231", format = "%Y%m%d"), - stateFIPS = "01", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_sampledata_by_state(parameter = "45201", - bdate = as.Date("19950515", format = "%Y%m%d"), - edate = as.Date("19950515", format = "%Y%m%d"), - stateFIPS = "37", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_annualsummary_by_state(parameter = "45201", - bdate = as.Date("19950515", - format = "%Y%m%d"), - edate = as.Date("19990515", - format = "%Y%m%d"), - stateFIPS = "37", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_dailysummary_by_state(parameter = "45201", - bdate = as.Date("19950515", format = "%Y%m%d"), - edate = as.Date("19950515", format = "%Y%m%d"), - stateFIPS = "37", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_qa_blanks_by_state(parameter = "88101", - bdate = as.Date("20180101", - format = "%Y%m%d"), - edate = as.Date("20180131", - format = "%Y%m%d"), - stateFIPS = "01", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_qa_collocated_assessments_by_state(parameter = "88101", - bdate = as.Date("20130101", - format = "%Y%m%d"), - edate = as.Date("20130131", - format = "%Y%m%d"), - stateFIPS = "01", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_qa_flowrateaudit_by_state(parameter = "88101", - bdate = as.Date("20180101", format = "%Y%m%d"), - edate = as.Date("20180131", format = "%Y%m%d"), - stateFIPS = "01", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_qa_flowrateverification_by_state(parameter = "88101", - bdate = as.Date("20170101", - format = "%Y%m%d"), - edate = as.Date("20190131", - format = "%Y%m%d"), - stateFIPS = "01", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_qa_one_point_qc_by_state(parameter = "44201", - bdate = as.Date("20180101", format = "%Y%m%d"), - edate = as.Date("20180131", format = "%Y%m%d"), - stateFIPS = "25", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_qa_one_point_qc_by_state(parameter = "44201", - bdate = as.Date("20180101", format = "%Y%m%d"), - edate = as.Date("20180131", format = "%Y%m%d"), - stateFIPS = "25", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_qa_pep_audit_by_state(parameter = "88101", - bdate = as.Date("20170101", format = "%Y%m%d"), - edate = as.Date("20171231", format = "%Y%m%d"), - stateFIPS = "01", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - -aqs_transactionsample_by_state(parameter = "45201", - bdate = as.Date("19950515", - format = "%Y%m%d"), - edate = as.Date("19950515", - format = "%Y%m%d"), - stateFIPS = "37", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_qa_annualperformanceeval_by_state(parameter = "44201", - bdate = as.Date("20170101", - format = "%Y%m%d"), - edate = as.Date("20171231", - format = "%Y%m%d"), - stateFIPS = "01", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_qa_annualperformanceevaltransaction_by_state(parameter = "44201", - bdate = as.Date("20170101", - format = "%Y%m%d"), - edate = as.Date("20171231", - format = "%Y%m%d"), - stateFIPS = "01", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - aqs_quarterlysummary_by_state(parameter = "88101", - bdate = as.Date("20160101", - format = "%Y%m%d"), - edate = as.Date("20171231", - format = "%Y%m%d"), - stateFIPS = "37", - return_header = TRUE - )[[1]]$Header$status %>% - expect_match(regexp = "Success") - - -}) diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-helperfunctions.R b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-helperfunctions.R deleted file mode 100644 index f5e0f9c..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/tests/testthat/test-helperfunctions.R +++ /dev/null @@ -1,72 +0,0 @@ -#' @importFrom magrittr `%>%`() -#' @importFrom stringr str_detect -#' @import testthat -test_that("helperfunctions (checkaqsparams()) functions", { -testthat::skip_if_offline() -testthat::skip_on_cran() -server <- "AQSDatamartAPI" - -if(file.exists("local.R")) -{ - source("helper.R") - AQScredentials <- RAQSAPItestsetup_helper() - datamartAPI_user <- AQScredentials$datamartAPI_user - datamartAPI_key <- AQScredentials$datamartAPI_key -} else { - datamartAPI_user <- Sys.getenv("RAQSAPIKEY", names = TRUE) - datamartAPI_key <- Sys.getenv("RAQSAPIUSERNAME", names = TRUE) -} -RAQSAPI::aqs_credentials(username = datamartAPI_user, - key = datamartAPI_key -) - -RAQSAPI:::checkaqsparams(parameter = "abcdefg") %>% - expect_error() -RAQSAPI:::checkaqsparams(bdate = "notadate") %>% - expect_error() -RAQSAPI:::checkaqsparams(edate = "notadate") %>% - expect_error() -RAQSAPI:::checkaqsparams(cbdate = "notadate") %>% - expect_error() -RAQSAPI:::checkaqsparams(cedate = "notadate") %>% - expect_error() -RAQSAPI:::checkaqsparams(stateFIPS = "90210") %>% - expect_error() -RAQSAPI:::checkaqsparams(countycode = "341478") %>% - expect_error() -RAQSAPI:::checkaqsparams(sitenum = "1") %>% - expect_error() -RAQSAPI:::checkaqsparams(cbsa_code = "something") %>% - expect_error() -RAQSAPI:::checkaqsparams(pqao_code = "99999") %>% - expect_error() -RAQSAPI:::checkaqsparams(minlat = "3245253") %>% - expect_error() -RAQSAPI:::checkaqsparams(maxlat = "647352") %>% - expect_error() -RAQSAPI:::checkaqsparams(minlon = 45425252) %>% - expect_error() -RAQSAPI:::checkaqsparams(maxlon = 463753415) %>% - expect_error() -RAQSAPI:::checkaqsparams(MA_code = "MA") %>% - expect_error() -RAQSAPI:::checkaqsparams(return_header = 1) %>% - expect_error() -RAQSAPI:::checkaqsparams(POC = "POC") %>% - expect_error() -RAQSAPI:::checkaqsparams(email = "not a valid email") %>% - expect_error() -RAQSAPI:::checkaqsparams(duration = "not a valid duration") %>% - expect_error() -RAQSAPI:::format_variables_for_api(x = list()) %>% - expect_equal("") -RAQSAPI:::format_multiple_params_for_api(x = list()) %>% - expect_equal("") -RAQSAPI:::aqsmultiyearparams(parameter = "99999", - bdate = as.Date("2000-01-01", format = "%Y-%m-%d"), - edate = as.Date("1999-01-01", format = "%Y-%m-%d"), - service = "not a service" - ) %>% - expect_error() -RAQSAPI:::format_variables_for_api(x = list()) %>% expect_equal("") -}) diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/AQSAPI.bib b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/AQSAPI.bib deleted file mode 100644 index ffe7ea7..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/AQSAPI.bib +++ /dev/null @@ -1,139 +0,0 @@ - @Manual{package:tibble, - title = {tibble: Simple Data Frames}, - author = {Kirill Müller and Hadley Wickham}, - year = {2021}, - note = {R package version 3.1.6}, - url = {https://CRAN.R-project.org/package=tibble}, - } - -@electronic{website:whatisR, - authors = "The R Foundation for Statistical Computing", - title = "What is {R}?", - month = "February", - year = "2020", - url = "https://www.r-project.org/about.html" -} - -@misc{cleanairact, - authors = "Environmental Protection Agency", - title = "Overview of the {C}lean {A}ir {A}ct and {A}ir {P}ollution", - month = "February", - year = "2021", - url = "https://www.epa.gov/clean-air-act-overview" -} - -@electronic{AboutAQSdata, - authors = "US EPA AQS Data Mart Team", - title = "About {AQS} Data", - month = "May", - year = "2019", - url = "https://aqs.epa.gov/aqsweb/documents/about_aqs_data.html", - note = "Version 1.1" -} - -@electronic{website:GNUproject, - authors = "Free Software Foundation", - title = "GNU Operating System", - month = "Feburaury", - year = "2020", - url = "https://www.gnu.org" -} - -@electronic{AQSDataMartWelcome, - authors = "US EPA AQS Data Mart Team", - title = "AQS Data Mart Welcome", - month = "Aug", - year = "2018", - url = "https://aqs.epa.gov/aqsweb/documents/data_mart_welcome.html" -} - -@book{book:RPackages, - author = "Hadley Wckham", - title = "R Packages", - ISBN = "1491910585, 9781491910580", - publisher = "O'Reilly Media Inc.", - year = "2015" -} - -@misc{website:RPackages, - author = "Hadley Wckham", - title = "R Packages", - publisher = "Hadley Wckham", - year = "2017", - url = "http://r-pkgs.had.co.nz/" -} - -@Manual{RBase, - title = "R: A Language and Environment for Statistical Computing", - author = "R Core Team", - organization = "R Foundation for Statistical Computing", - address = "Vienna, Austria", - year = "2019", - url = "https://www.R-project.org/", - } - -@Manual{WritingRexensions, - author = {\relax R Development Core Team}, - title="Writing R Extensions", - organization = "Comprehensive R Archive Network", - year = "2019", - url = "https://cran.r-project.org/doc/manuals/r-release/R-exts.html" -} - -@Manual{Tidyversestyleguide, - author = "Hadley Wckham", - title = "Tidyverse Style Guide", - url = "https://style.tidyverse.org/", - year = "2020" -} - -@Manual{CRANRepoPolicy, - author = {\relax CRAN Repository Maintainers}, - title = "CRAN Repository Policy", - organization = "The Comprehensive R Archive Network", - revision = "4197", - url = "https://cran.r-project.org/submit.html" -} - - @Manual{package:badgecreatr, - title = {badgecreatr: Create Badges for 'Travis', 'Repostatus' 'Codecov.io' - Etc in Github Readme}, - author = {Roel M. Hogervorst}, - year = {2019}, - note = {R package version 0.2.0}, - url = {https://CRAN.R-project.org/package=badgecreatr}, - } - - @Manual{package:usethis, - title = {usethis: Automate Package and Project Setup}, - author = {Hadley Wickham and Jennifer Bryan and Malcolm Barrett}, - year = {2021}, - note = {R package version 2.1.3}, - url = {https://CRAN.R-project.org/package=usethis}, - } - - @Manual{package:lintr, - title = {lintr: A 'Linter' for R Code}, - author = {Jim Hester and Florent Angly and Russ Hyde}, - year = {2020}, - note = {R package version 2.0.1}, - url = {https://CRAN.R-project.org/package=lintr}, - } - - @Manual{package:remotes, - title = {remotes: R Package Installation from Remote Repositories, Including - 'GitHub'}, - author = {Gábor Csárdi and Jim Hester and Hadley Wickham and Winston Chang - and Martin Morgan and Dan Tenenbaum}, - year = {2021}, - note = {R package version 2.4.2}, - url = {https://CRAN.R-project.org/package=remotes}, - } - -@Manual{package:hexsticker, - title = {hexSticker: Create Hexagon Sticker in R}, - author = {Guangchuang Yu}, - year = {2020}, - note = {R package version 0.4.9}, - url = {https://CRAN.R-project.org/package=hexSticker}, - } diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/Acknowledgements.Rmd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/Acknowledgements.Rmd deleted file mode 100644 index c80f9e4..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/Acknowledgements.Rmd +++ /dev/null @@ -1,32 +0,0 @@ ---- -title: RAQSAPI - Acknowledgements -author: Clinton Mccrowey physical scientist - US EPA -output: - rmarkdown::html_vignette: default -lang: en-US -vignette: > - %\VignetteIndexEntry{RAQSAPI - Acknowledgements} - %\VignetteEncoding{UTF-8} - %\VignetteDepends{knitr} - %\VignetteDepends{rmarkdown} - %\VignetteEngine{knitr::rmarkdown} ---- - -# Acknowledgements -RAQSAPI was included in the Rblogger's March 2021: “Top 40” [New CRAN Packages](https://www.r-bloggers.com/2021/04/march-2021-top-40-new-cran-packages/). - - The RAQSAPI package borrows upon functions and code provided by sources not -mentioned in the DESCRIPTION file. Here we attempt to acknowledge those sources -with them RAQSAPI would not be possible. - -* README badges are provided by R package `badgecreator`[@package:badgecreatr]. -* The R package `usethis`[@package:usethis] was used to generate GitHub actions - for Continuous integration (CI). -* Code cleanup was assisted by the R package `lintr`[@package:lintr] -* the function *install.packages* are provided by the R package `utils`[@RBase] -* the function *install_github* are provided by the R package `remotes`[ - @package:remotes] -* .gitignore file borrowed examples from - https://github.com/github/gitignore/blob/master/R.gitignore -* The RAQSAPI hexsticker was created using the - `hexSticker`[@package:hexsticker] package for R diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/EPA_Disclaimer.Rmd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/EPA_Disclaimer.Rmd deleted file mode 100644 index 5bbfa85..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/EPA_Disclaimer.Rmd +++ /dev/null @@ -1,31 +0,0 @@ ---- -title: RAQSAPI - EPA Disclaimer -author: -- affiliation: |- - United States Environmental Protection Agency (US EPA), - Region III, - Air and Radiation Division, - Air Quality and Analysis Branch - name: Clinton Mccrowey -output: - rmarkdown::html_vignette: default -vignette: > - %\VignetteIndexEntry{RAQSAPI - EPA Disclaimer} - %\VignetteEncoding{UTF-8} - %\VignetteDepends{knitr} - %\VignetteDepends{rmarkdown} - %\VignetteEngine{knitr::rmarkdown} ---- - -# EPA Disclaimer - -This software/application was developed by the U.S. Environmental Protection -Agency (USEPA). No warranty expressed or implied is made regarding the accuracy -or utility of the system, nor shall the act of distribution constitute any such -warranty. The USEPA has relinquished control of the information and no longer -has responsibility to protect the integrity, confidentiality or availability of -the information. Any reference to specific commercial products, processes, or -services by service mark, trademark, manufacturer, or otherwise, does not -constitute or imply their endorsement, recommendation or favoring by the USEPA. -The USEPA seal and logo shall not be used in any manner to imply endorsement of -any commercial product or activity by the USEPA or the United States Government. diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/InstallandSetup.Rmd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/InstallandSetup.Rmd deleted file mode 100644 index d22b6a1..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/InstallandSetup.Rmd +++ /dev/null @@ -1,47 +0,0 @@ ---- -title: RAQSAPI - Install and Setup -author: -- affiliation: |- - United States Environmental Protection Agency (US EPA), - Region III, - Air and Radiation Division, - Air Quality and Analysis Branch - name: Clinton Mccrowey -output: - rmarkdown::html_vignette: default -vignette: > - %\VignetteIndexEntry{RAQSAPI - Install and Setup} - %\VignetteEncoding{UTF-8} - %\VignetteDepends{knitr} - %\VignetteDepends{rmarkdown} - %\VignetteEngine{knitr::rmarkdown} ---- - -# Installing RAQSAPI - -Either install the stable version from CRAN or install the latest -development version from GitHub. - -## Option 1: Installing the stable version from CRAN - -```R -install.packages(pkgs="RAQSAPI", dependencies = TRUE ) -``` - -## Option 2: Installing the development version of RAQSAPI - -To install the development version of `RAQSAPI`, first if not already installed, -install the `remotes` package and its dependencies. Then run the following in a -R environment. - -```R -remotes::install_github(repo = "USEPA/raqsapi", - dependencies = TRUE, - upgrade = "always", - build = TRUE, - #optional, set TRUE if the manual is desired, - #requires pandoc - build_manual = FALSE, - build_vignettes = TRUE - ) -``` diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/Intro.Rmd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/Intro.Rmd deleted file mode 100644 index 9e289b5..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/Intro.Rmd +++ /dev/null @@ -1,57 +0,0 @@ ---- -title: RAQSAPI - Introduction to RAQSAPI -author: Clinton Mccrowey physical scientist - US EPA -output: - rmarkdown::html_vignette: default -vignette: > - %\VignetteIndexEntry{RAQSAPI - Introduction to RAQSAPI} - %\VignetteEncoding{UTF-8} - %\VignetteDepends{knitr} - %\VignetteDepends{rmarkdown} - %\VignetteEngine{knitr::rmarkdown} ---- - -| Warning: US EPA's AQS Data Mart API V2 is currently \ -in beta phase of development, the API interface has not been finalized. \ -This means that certain functionality of the API may change or be removed \ -without notice. As a result, this package is also currently marked as beta and \ -may also change to reflect any changes made to the Data Mart API or in respect \ -to improvements in the design, functionality, quality and documentation of \ -this package. The authors assume no liability for any problems that may occur \ -as a result of using this package, the Data Mart service, any software, \ -service, hardware, or user accounts that may utilize this package. | -| -- | - -# Introduction - -The `RAQSAPI` package for the R programming environment allows a R programming - environment to connect to and retrieve data from the United States - Environmental Protection Agency's (US EPA) Air Quality System (AQS) Data Mart - API v2 Air Quality System[@AQSDataMartWelcome] - interface directly. This package enables the data user to omit legacy - challenges including coercing data from a JSON object to a usable R object, - retrieving multiple years of data, formatting API requests, retrieving - results, handling credentials, requesting multiple pollutant data and rate - limiting data requests. All the basic functionality of the API have been - implemented that are available from the AQS API Data Mart server. The library - connects to AQS Data Mart API via Hypertext Transfer Protocol (HTTP) so there - is no need to install external ODBC drivers, configure ODBC connections or - deal with the security vulnerabilities associated with them. Most functions - have a parameter, return_header which by default is set to FALSE. If the user - decides to set return_header to TRUE, then that function will return a R - AQS_DATAMART_APIv2 S3 object which is a two item named list. - The first item, (\$Header) in the AQS_DATAMART_APIv2 object is a - tibble[@package:tibble] - which contains the header information. The Header contains status - information regarding the request (success/fail), any applicable error - messages returned from the API, if any exist, the URL used in the request, a - date and time stamp noting when request was received and other useful - information. The second item of the AQS_DATAMART_APIv2 object (\$Data) is a - tibble which contains the actual data being requested. For functions with the - return_header option set to FALSE (default) a simple tibble is returned with - just the $Data portion of the request. After each call to the API a five - second stall is invoked to help prevent overloading the Data Mart API server - and to serve as a simple rate limit. ^[RAQSAPI's rate limit does not - guarantee that the user will not go over the rate limit and does not guarantee - that API calls do not overload the AQS Data Mart system, each user should - monitor their requests independently.] diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/RAQSAPIFunctions-Brief.Rmd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/RAQSAPIFunctions-Brief.Rmd deleted file mode 100644 index bdaaac7..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/RAQSAPIFunctions-Brief.Rmd +++ /dev/null @@ -1,88 +0,0 @@ ---- -title: RAQSAPI - A Brief introduction into RAQSAPI functions -author: Clinton Mccrowey physical scientist - US EPA -output: - rmarkdown::html_vignette: default -vignette: > - %\VignetteIndexEntry{RAQSAPI - A Brief introduction into RAQSAPI functions} - %\VignetteEncoding{UTF-8} - %\VignetteDepends{knitr} - %\VignetteDepends{rmarkdown} - %\VignetteEngine{knitr::rmarkdown} ---- - - -| Information: AQS Data Mart API restricts the \ -maximum amount of monitoring data to one full year of data per API \ -call. | -| -- | - -RAQSAPI functions are named according to the service and filter variables that -are available by the Data Mart -API.^[See (https://aqs.epa.gov/aqsweb/documents/data_api.html) for the full -details of the Data Mart API] - -## Data Mart aggregate functions - -These functions retrieve aggregated data from the Data Mart API and are grouped -by how each function aggregates the data. There are 7 different families of -related aggregate functions in which the AQS Data Mart API groups data. - -**These seven families are**: - - - **\_by_site** - - **\_by_county** - - **\_by_state** - - **\_by\_\** (_by_box) - - **\_by\_\** (_by_MA) - - **\_by\_\** (_by_pqao) - - **\_by\_\** (_by_cbsa). - -Within these families of aggregated data functions there are functions that call -on the 13 different aggregate services that the Data Mart API provides. -**Note that not all aggregations are available for each service.** - - -**These fourteen services are**: - - - **Monitors** (aqs_monitors_by_*) - - **Sample Data** (aqs_sampledata_by_*) - - **Daily Summary Data** (aqs_dailysummary_by_*) - - **Annual Summary Data** (aqs_annualsummary_by_*) - - **Quarterly Summary Data** (aqs_quarterlysummary_by_*) - - **Quality Assurance - Blanks Data** (aqs_qa_blanks_by_*) - - **Quality Assurance - Collocated Assessments** - (aqs_qa_collocated_assessments_by_*) - - **Quality Assurance - Flow Rate Verifications** - (aqs_qa_flowrateverification_by_*) - - **Quality Assurance - Flow Rate Audits** (aqs_qa_flowrateaudit_by_*) - - **Quality Assurance - One Point Quality Control Raw Data** - (aqs_qa_one_point_qc_by_*) - - **Quality Assurance - PEP Audits** (aqs_qa_pep_audit_by_*) - - **Transaction Sample - AQS Submission data in transaction Format (RD)** - (aqs_transactionsample_by_*) - - **Quality Assurance - Annual Performance Evaluations** \ - (aqs_qa_annualperformanceeval_by_*) - - **Quality Assurance - Annual Performance Evaluations in the AQS** \ - **Submission transaction format (RD)** - (aqs_qa_annualperformanceevaltransaction_by_*) - -| Information: AQS Data Mart API restricts the \ -maximum amount of monitoring data to one full year of data per \ -API call. These functions are able to return multiple years of data by \ -making repeated calls to the API. Each call to the Data Mart API will take \ -time to complete. The more years of data being requested the longer RAQSAPI \ -will take to return the results. | -| -- | - -Aggregate functions are named AQS_API\\_\() where -\ is one of the 13 services listed above and \ is -either "\_by\_site", "\_by\_county", "\_by\_state", "\_by\_box", "\_by\_cbsa", -"\_by\_ma", or "\_by\_pqao". - -### See the RAQSAPI vignette for more details -(RAQSAPI must be installed and built with BUILD_MANUAL = TRUE enabled) -```R - RShowDoc(what="RAQSAPIvignette", type="html", package="RAQSAPI") -``` diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/RAQSAPIFunctions-Long.Rmd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/RAQSAPIFunctions-Long.Rmd deleted file mode 100644 index 44a9c91..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/RAQSAPIFunctions-Long.Rmd +++ /dev/null @@ -1,727 +0,0 @@ ---- -title: RAQSAPI - RAQSAPI functions Long version -author: Clinton Mccrowey physical scientist - US EPA -output: - rmarkdown::html_vignette: default -vignette: > - %\VignetteIndexEntry{RAQSAPI - RAQSAPI functions Long version} - %\VignetteEncoding{UTF-8} - %\VignetteDepends{knitr} - %\VignetteDepends{rmarkdown} - %\VignetteEngine{knitr::rmarkdown} ---- -# RAQSAPI functions -The RAQSAPI library exports the following functions (in alphabetical order): - -```{r RAQSAPIfun_all, echo = FALSE, comment = NA} -knitr::opts_chunk$set(collapse = TRUE, comment = "#>" ) -invisible(library(magrittr, warn.conflicts = FALSE, quietly = TRUE)) -invisible(library(stringr, warn.conflicts = FALSE, quietly = TRUE)) -invisible(library(tibble, warn.conflicts = FALSE, quietly = TRUE)) -invisible(library(glue, warn.conflicts = FALSE, quietly = TRUE)) - -#AQAD-33, using list.files works when knitting the vignette but does -#not seem to work when the vignette is knitted as part of a package. -#Instead function names need to be hard coded. -# RAQSAPI_functions <- list.files(path = "./man/", pattern = ".Rd$") %>% -# stringr::str_remove_all(pattern = ".Rd") %>% -# str_replace("ni_infix_operator", replacement = NA_character_) %>% -# str_replace("RAQSAPI", replacement = NA_character_) %>% -# str_replace_all("_services_", replacement = NA_character_) %>% -# na.omit() %>% -# as.character() -RAQSAPI_functions <- c( -"aqs_annualsummary_by_box", -"aqs_annualsummary_by_cbsa", -"aqs_annualsummary_by_county", -"aqs_annualsummary_by_site", -"aqs_annualsummary_by_state", -"aqs_cbsas", -"aqs_classes", -"aqs_counties_by_state", -"aqs_credentials", -"aqs_dailysummary_by_box", -"aqs_dailysummary_by_cbsa", -"aqs_dailysummary_by_county", -"aqs_dailysummary_by_site", -"aqs_dailysummary_by_state", -"aqs_fields_by_service", -"aqs_isavailable", -"aqs_knownissues", -"aqs_mas", -"aqs_monitors_by_box", -"aqs_monitors_by_cbsa", -"aqs_monitors_by_county", -"aqs_monitors_by_site", -"aqs_monitors_by_state", -"aqs_parameters_by_class", -"aqs_pqaos", -"aqs_qa_annualperformanceeeval_by_county", -"aqs_qa_annualperformanceeval_by_MA", -"aqs_qa_annualperformanceeval_by_pqao", -"aqs_qa_annualperformanceeval_by_site", -"aqs_qa_annualperformanceeval_by_state", -"aqs_qa_annualperformanceevaltransaction_by_county", -"aqs_qa_annualperformanceevaltransaction_by_MA", -"aqs_qa_annualperformanceevaltransaction_by_pqao", -"aqs_qa_annualperformanceevaltransaction_by_site", -"aqs_qa_annualperformanceevaltransaction_by_state", -"aqs_qa_blanks_by_county", -"aqs_qa_blanks_by_MA", -"aqs_qa_blanks_by_pqao", -"aqs_qa_blanks_by_site", -"aqs_qa_blanks_by_state", -"aqs_qa_collocated_assessments_by_county", -"aqs_qa_collocated_assessments_by_MA", -"aqs_qa_collocated_assessments_by_pqao", -"aqs_qa_collocated_assessments_by_site", -"aqs_qa_collocated_assessments_by_state", -"aqs_qa_flowrateaudit_by_county", -"aqs_qa_flowrateaudit_by_MA", -"aqs_qa_flowrateaudit_by_pqao", -"aqs_qa_flowrateaudit_by_site", -"aqs_qa_flowrateaudit_by_state", -"aqs_qa_flowrateverification_by_county", -"aqs_qa_flowrateverification_by_MA", -"aqs_qa_flowrateverification_by_pqao", -"aqs_qa_flowrateverification_by_site", -"aqs_qa_flowrateverification_by_state", -"aqs_qa_one_point_qc_by_county", -"aqs_qa_one_point_qc_by_MA", -"aqs_qa_one_point_qc_by_pqao", -"aqs_qa_one_point_qc_by_site", -"aqs_qa_one_point_qc_by_state", -"aqs_qa_pep_audit_by_county", -"aqs_qa_pep_audit_by_MA", -"aqs_qa_pep_audit_by_pqao", -"aqs_qa_pep_audit_by_site", -"aqs_qa_pep_audit_by_state", -"aqs_quarterlysummary_by_box", -"aqs_quarterlysummary_by_county", -"aqs_quarterlysummary_by_pqao", -"aqs_quarterlysummary_by_site", -"aqs_quarterlysummary_by_state", -"aqs_removeheader", -"aqs_revisionhistory", -"aqs_sampledata_by_box", -"aqs_sampledata_by_cbsa", -"aqs_sampledata_by_county", -"aqs_sampledata_by_site", -"aqs_sampledata_by_state", -"aqs_sampledurations", -"aqs_sign_up", -"aqs_sites_by_county", -"aqs_states", -"aqs_transactionsample_by_county", -"aqs_transactionsample_by_site", -"aqs_transactionsample_by_state", -"aqs_transactionsample_by_MA" -) - -RAQSAPI_functions %>% - cat(sep = " \n") -``` - -RAQSAPI functions are named according to the service and filter variables that -are available by the AQS Data Mart API.^[See -(https://aqs.epa.gov/aqsweb/documents/data_api.html) for full details of the -Data Mart API] - -# Variable descriptions and usage. -These are all the available variables that can be used with various functions -exported from the RAQSAPI library listed alphabetically. Not all of these -variables are used with every function, and not all of these parameters are -required. See the -[RAQSAPI functional families](#RAQSAPI functional families) section to -see which parameters are used with each function. - -* AQSobject: a R S3 object that is returned from RAQSAPI aggregate functions - where return_header is TRUE. An AQS_Data_Mart_APIv2 is a 2 item - named list in which the first item (\$Header) is a tibble of - header information from the AQS API and the second item (\$Data) - is a tibble of the data returned. - -* bdate: a R date object which represents the begin date of the data selection. - Only data on or after this date will be returned. - -* cbdate (optional): a R date object which represents the "beginning date of - last change" that indicates when the data was last - updated. cbdate is used to filter data based on the - change date. Only data that changed on or after this date - will be returned. This is an optional variable which - defaults to NA. - -* cedate (optional): a R date object which represents the "end date of last - change" that indicates when the data was last updated. - cedate is used to filter data based on the change date. - Only data that changed on or before this date will be - returned. This is an optional variable which defaults to - NA. - -* countycode: a R character object which represents the 3 digit state FIPS code - for the county being requested (with leading zero(s)). Refer to - [aqs_counties_by_state()] for a table of available county - codes for each state. - -* duration (optional): a R character string that represents the parameter - duration code that limits returned data to a specific - sample duration. The default value of NA_character_ - will result in no filtering based on duration code. - Valid durations include actual sample - durations and not calculated durations such as 8 hour - CO or O${_3}$ rolling averages, 3/6 day PM averages or - Pb 3 month rolling averages. Refer to - [aqs_sampledurations()] for a table of all available - duration codes. - -* edate: a R date object which represents the end date of the data selection. - Only data on or before this date will be returned. - -* email: a R character object which represents the email account that will be - used to register with the AQS API or change an existing user's key. A - verification email will be sent to the account specified. - -* key: the key used in conjunction with the username given to connect to AQS - Data Mart. - -* MA_code: a R character object which represents the 4 digit AQS Monitoring - Agency code (with leading zeroes). -* maxlat: a R character object which represents the maximum latitude of a - geographic box. Decimal latitude with north begin positive. Only - data south of this latitude will be returned. - -* maxlon: a R character object which represents the maximum longitude of a - geographic box. Decimal longitude with east being positive. Only - data west of this longitude will be returned. Note that -80 is less - than -70. - -* minlat: a R character object which represents the minimum latitude of a - geographic box. Decimal latitude with north being positive. - Only data north of this latitude will be returned. - -* minlon: a R character object which represents the minimum longitude of a - geographic box. Decimal longitude with east begin positive. Only - data east of this longitude will be returned. - -* parameter: a R character list or single character object which represents - the parameter code of the air pollutant related to the data - being requested. - -* return_header If FALSE (default) only returns data requested. If TRUE - returns a AQSAPI_v2 object which is a two item list that - contains header information returned from the API server - mostly used for debugging purposes in addition to the - data requested. - -* service a string which represents the services provided by the AQS - API. For a list of available services refer to - https://aqs.epa.gov/aqsweb/documents/data_api.html#services - for the complete listing of services available through the - Datamart API - -* sitenum: a R character object which represents the 4 digit site number (with - leading zeros) within the county and state being requested. - -* stateFIPS: a R character object which represents the 2 digit state FIPS code - (with leading zero) for the state being requested. - -* pqao_code: a R character object which represents the 4 digit AQS Primary - Quality Assurance Organization code (with leading zeroes). - -* username: a R character object which represents the email account that will - be used to connect to the AQS API. - - - -# RAQSAPI functional families -## Sign up and credentials -The functions included in this family of functions are: - -```{r SIGNUPANDCREDENTIALS, echo = FALSE, comment = NA} -signupandcredentials <- paste(".sign_up", ".credentials", sep = '|') - -str_subset(string = RAQSAPI_functions, pattern = signupandcredentials) %>% - cat(sep = " \n") -``` -These functions are used to sign up with Data Mart and to store credential - information to use with RAQSAPI. The RAQSAPI::aqs_signup function takes - one parameter: - -* email: - -The RAQSAPI::aqs_credentials function takes two parameters: - -* username: -* key: - -## Data Mart API metadata functions -```{r METADATAFUNCTIONS, echo = FALSE, comment = NA} -metadatafunctions <- paste(".available", - ".field_by_service", - ".knownissues", sep = '|') - -str_subset(string = RAQSAPI_functions, pattern = metadatafunctions) %>% - cat(sep = " \n") -``` -These functions return Data Mart meta data - -The RAQSAPI::aqs_isavailable function takes no parameters and returns a - table which details the status of the AQS API. - -The RAQSAPI::aqs_field_by_Service function takes one parameter, service, - which is a R character object which represents the services provided by - the AQS API. For a list of available services see - [Air Quality System (AQS) API - Services Overview]( - https://aqs.epa.gov/aqsweb/documents/data_api.html#services) - -The RAQSAPI::aqs_knownissues function takes no parameters and Returns a - table of any known issues with system functionality or the data. These are - usually issues that have been identified internally and will require some - time to correct in Data Mart or the API. This function implements a direct - API call to Data Mart and returns data directly from the API. Issues - returned via this function do not include any issues from the RAQSAPI R - package. - -The RAQSAPI::aqs_revisionhistory function is used to query Data Mart for the - change history to the API. - -## Data Mart API list functions -```{r LISTFUNCTIONS, echo = FALSE, comment = NA} -listfunctions <- paste(".states", - ".counties_by_state", - ".sites_by_county", - ".cbsas", - ".classes", - ".pqaos", - ".mas", - sep = '|' - ) - -str_subset(string = RAQSAPI_functions, pattern = listfunctions) %>% - cat(sep = " \n") -``` -List functions return options or groupings that can be used in conjunction with - other API calls. By default each function in this category returns results - as a tibble. If return_header parameter is set to TRUE a AQSAPI_v2 object is - returned instead. - -RAQSAPI::aqs_cbsas returns a table of all available Core Based Statistical - Areas (cbsas) and their respective cbsa codes. - -RAQSAPI::aqs_states takes no arguments and returns a table of the available - states and their respective state FIPS codes. - -RAQSAPI::aqs_sampledurations takes no arguments and returns a table of the - available sample duration code used to construct other requests. - -RAQSAPI::aqs_classes takes no arguments and returns a table of parameter - classes (groups of parameters, i.e. "criteria" or "all"). - -RAQSAPI::aqs_counties_by_state takes one parameter, stateFIPS, which is a two - digit state FIPS code for the state being requested represented as a - R character object and returns a table of counties and their - respective FIPS code for the state requested. Use RAQSAPI::aqs_states to - receive a table of valid state FIPS codes. - -RAQSAPI::aqs_sites_by_county takes two parameters, stateFIPS, which is a - two digit state FIPS code for the state being requested and county_code - which is a three digit county FIPS code for the county being requested, - both stateFIPS and county_code should be encoded as a R character object - This function returns a table of all air monitoring sites with the - requested state and county FIPS code combination. - -RAQSAPI::aqs_pqaos takes no parameters and returns an AQS_DATAMART_APIv2 - S3 object containing a table of primary quality assurance - organizations (pqaos). - -RAQSAPI::aqs_mas takes no parameters and returns an AQS_DATAMART_APIv2 S3 - object containing a table of monitoring agencies (MA). - -## Data Mart aggregate functions - -| Information: AQS Data Mart API restricts the \ -maximum amount of monitoring data to one full year of data per \ -API call. These functions are able to return multiple years of data by \ -making repeated calls to the API. Each call to the Data Mart API will take \ -time to complete. The more years of data being requested the longer RAQSAPI \ -will take to return the results. | -| -- | - -These functions retrieve aggregated data from the Data Mart API and are - grouped by how each function aggregates the data. There are 5 different - families of related aggregate functions. These families are arranged by how - the Data Mart API groups the returned data, _by_site, _by_county, _by_state, - _by_ (_by_box) and - _by_ (_by_cbsa). Within each family - of aggregated data functions there are functions that call on the 10 - different services that the Data Mart API provides. All Aggregate - functions return a tibble by default. If the return_Header parameter is - set to TRUE an AQS_DATAMART_APIv2 S3 object is returned instead. - -* **These fourteen services are**: -1. **Monitors**: Returns operational information about the samplers (monitors) - used to collect the data. Includes identifying information, - operational dates, operating organizations, etc. Functions - using this service contain *\*monitors_by_*\* in the function - name. -2. **Sample Data**: Returns sample data - the most fine grain data reported to - EPA. Usually hourly, sometimes 5-minute, 12-hour, etc. - This service is available in several geographic selections - based on geography: site, county, state, cbsa (core based - statistical area, a grouping of counties), or - by latitude/longitude bounding box. Functions using this - service contain *\*sampledata_by_*\* in the function name. - All Sample Data functions accept two additional, optional - parameters; cbdate and cedate: - + cbdate: a R date object which represents a "beginning date of last - change" that indicates when the data was last updated. - cbdate is used to filter data based on the change date. - Only data that changed on or after this date will be - returned. This is an optional variable which defaults to - NA_Date_. - + cedate: a R date object which represents an "end date of last change" - that indicates when the data was last updated. cedate is - used to filter data based on the change date. Only data - that changed on or before this date will be returned. This - is an optional variable which defaults to NA_Date_. - + duration: an optional R character string that represents the - parameter duration code that limits returned data to - a specific sample duration. The default value of - NA_character_ results in no filtering based on - duration code. Valid durations include actual sample - durations and not calculated durations such as 8 hour - CO or $O_3$ rolling averages, 3/6 day PM averages or - Pb 3 month rolling averages. Refer to - [aqs_sampledurations()] for a list of all available - duration codes. -3. **Daily Summary Data**: Returns data summarized at the daily level. All daily - summaries are calculated on midnight to midnight - basis in local time. Variables returned include - date, mean value, maximum value, etc. Functions - using this service contain *\*dailysummary_by_*\* in - the function name. All Daily Summary Data functions - accept two additional parameters; cbdate and cedate: - + cbdate: a R date object which represents a "beginning date of last - change" that indicates when the data was last updated. - cbdate is used to filter data based on the change date. Only - data that changed on or after this date will be returned. - This is an optional variable which defaults to NA_Date_. - + cedate: a R date object which represents an "end date of last change" - that indicates when the data was last updated. cedate is - used to filter data based on the change date. Only data that - changed on or before this date will be returned. This is an - optional variable which defaults to NA_Date_. -4. **Annual Summary Data**: Returns data summarized at the yearly level. - Variables include mean value, maxima, percentiles, - etc. Functions using this service contain - *\*annualdata_by_*\* in the function name. All - Annual Summary Data functions accept two - additional parameters; cbdate and cedate: - + cbdate: a R date object which represents a "beginning date of last - change" that indicates when the data was last updated. cbdate - is used to filter data based on the change date. Only data - that changed on or after this date will be returned. This is - an optional variable which defaults to NA_Date_. - + cedate: a R date object which represents an "end date of last change" - that indicates when the data was last updated. cedate is used - to filter data based on the change date. Only data that - changed on or before this date will be returned. This is an - optional variable which defaults to NA_Date_. -5. **Quarterly Summary Data**: Returns data summarized at the quarterly level. - Variables include mean value, maxima, percentiles, - etc. Functions using this service contain - *\*quarterlydata_by_*\* in the function name. All - Annual Summary Data functions accept two - additional parameters; cbdate and cedate: - + cbdate: a R date object which represents a "beginning date of last - change" that indicates when the data was last updated. cbdate - is used to filter data based on the change date. Only data - that changed on or after this date will be returned. This is - an optional variable which defaults to NA_Date_. - + cedate: a R date object which represents an "end date of last change" - that indicates when the data was last updated. cedate is used - to filter data based on the change date. Only data that - changed on or before this date will be returned. This is an - optional variable which defaults to NA_Date_. -6. **Quality Assurance - Blanks Data**: - Quality assurance data - blanks samples. - Blanks are unexposed sample collection devices - (e.g., filters) that are transported with the - exposed sample devices to assess if contamination - is occurring during the transport or handling of - the samples. Functions using this service contain - *\*qa\_blanks_by_*\* in the function name. -7. **Quality Assurance - Collocated Assessments**: - Quality assurance data - collocated assessments. - Collocated assessments are pairs of samples - collected by different samplers at the same time and - place. (These are "operational" samplers, - assessments with independently calibrated samplers - are called "audits".). Functions using this service - contain *\*qa_collocated_assessments_by_*\* in the - function name. -8. **Quality Assurance - Flow Rate Verifications**: - Quality assurance data - flow rate verifications. - Several times per year, each PM monitor must have it's - (fixed) flow rate verified by an operator taking a - measurement of the flow rate. Functions using this - service contain *\*qa_flowrateverification_by_*\* in - the function name. -9. **Quality Assurance - Flow Rate Audits**: - Quality assurance data - flow rate audits. At least twice - year, each PM monitor must have it's flow rate - measurement audited by an expert using a different - method than is used for flow rate verifications. - Functions using this service contain - *\*qa_flowrateaudit_by_*\* in the function name. -10. **Quality Assurance - One Point Quality Control Raw Data**: - Quality assurance data - one point quality control check - raw data. At least every two weeks, certain gaseous - monitors must be challenged with a known concentration to - determine monitor performance. Functions using this - service contain *\*qa_one_point_qc_by_*\* in the function - name. -11. **Quality Assurance - pep Audits**: - Quality assurance data - performance evaluation program - (pep) audits. pep audits are independent assessments used - to estimate total measurement system bias with a primary - quality assurance organization. Functions using this - service contain *\*qa_pep_audit_by_*\* in the function - name. - -12. **Transaction Sample - AQS Submission data in transaction format (RD)**: - Transaction sample data - The raw transaction sample data - uploaded to AQS by the agency responsible for data - submissions in RD format. Functions using this - service contain *\*transactionsample_by_*\* in the - function name. Transaction sample data is only available - aggregated by site, county, state or monitoring agency. - -13. **Quality Assurance - Annual Performance Evaluations**: - Quality assurance data - Annual performance evaluations. - A performance evaluation must be conducted on each primary - monitor once per year. The percent differences between - known and measured concentrations at several levels are - used to assess the quality of the monitoring data. - Functions using this service contain - *\*aqs_qa_annualperformanceeval_by_*\* in the function - name. Annual performance in transaction format are - only available aggregated by site, county, state, - monitoring agency, and primary quality assurance - organization. Annual performance evaluations are only - available aggregated by site, county, state, - monitoring agency, and primary quality assurance - organization. - -14. **Quality Assurance - Annual performance Evaluations in transaction** \ - **format (RD)**: - Quality assurance data - The raw transaction annual - performance evaluations data in RD format. Functions using - this service contain - *\*aqs_qa_annualperformanceevaltransaction_by_*\* in the - function name. Annual performance evaluations in transaction - format are only available aggregated by site, county, state, - monitoring agency, and primary quality assurance - organization. - - -### Data Mart aggregate functions _by_site -```{r _by_Sitefunctions, echo = FALSE, comment = NA} -by_sitefunctions <- paste("_by_site", sep = '|') - -str_subset(string = RAQSAPI_functions, pattern = by_sitefunctions) %>% - cat(sep = " \n") -``` -functions in this family of functions aggregate data at the site level. All - \*_by_site functions accept the following variables: - -* parameter: -* bdate: -* edate: -* stateFIPS: -* countycode: -* sitenum: -* cbdate (optional): (This parameter is only used in conjunction with - *\*sampledata_by_*\*, *\*dailysummary_by_*\*, - *\*annualdata_by_*\* functions and - *\*quarterlysummary_by_*\* functions). -* cedate (optional): (This parameter is only used in conjunction with - *\*sampledata_by_*\*, *\*dailysummary_by_*\*, - *\*annualdata_by_*\* functions and - *\*quarterlysummary_by_*\* functions). -* return_header (optional): set to FALSE by default. -* duration (optional): (This parameter is only used in conjunction with - *\*sampledata_by_*\* functions). - -### Data Mart aggregate functions _by_county -```{r _by_countyfuncions, echo = FALSE, comment = NA} -by_countyfunctions <- paste("._by_county", sep = '|') - -str_subset(string = RAQSAPI_functions, pattern = by_countyfunctions) %>% - cat(sep = " \n") -``` -functions in this family of functions aggregate data at the county level. - All functions accept the following variables: - -* parameter: -* bdate: -* edate: -* stateFIPS: -* countycode: -* cbdate (optional): (This parameter is only used in conjunction with - *\*sampledata_by_*\*, *\*dailysummary_by_*\*, - *\*annualdata_by_*\* and - *\*quarterlysummary_by_*\* functions). -* cedate (optional): (This parameter is only used in conjunction with - *\*sampledata_by_*\*, *\*dailysummary_by_*\*, - *\*annualdata_by_*\* and - *\*quarterlysummary_by_*\* functions). -* return_header (optional): set to FALSE by default. -* duration (optional): (This parameter is only used in conjunction with - *\*sampledata_by_*\* functions). - -### Data Mart aggregate functions by Monitoring agency (MA) - -```{r _by_STATEfunctions, echo = FALSE, comment = NA} -by_STATEfunctions <- paste("._by_state", sep = '|') - -str_subset(string = RAQSAPI_functions, pattern = by_STATEfunctions) %>% - cat(sep = " \n") -``` -functions in this family of functions aggregate data at the state level. - All functions accept the following variables: - -* parameter: -* bdate: -* edate: -* stateFIPS: -* cbdate (optional): (This parameter is only used in conjunction with - *\*sampledata_by_*\*, *\*dailysummary_by_*\*, - *\*annualdata_by_*\* functions and - *\*quarterlysummary_by_*\* functions). -* cedate (optional): (This parameter is only used in conjunction with - *\*sampledata_by_*\*, *\*dailysummary_by_*\*, - *\*annualdata_by_*\* and - *\*quarterlysummary_by_*\* functions). -* return_header (optional): set to FALSE by default. -* duration (optional): (This parameter is only used in conjunction with - *\*sampledata_by_*\* functions). - -```{r _by_MAfunctions, echo = FALSE, comment = NA} -by_MAfunctions <- paste("._by_MA", sep = '|') - -str_subset(string = RAQSAPI_functions, pattern = by_MAfunctions) %>% - cat(sep = " \n") -``` -functions in this family of functions aggregate data at the Monitoring Agency - (MA) level. All functions accept the following variables: - -* parameter: -* bdate: -* edate: -* MA_code: -* cbdate (optional): (This parameter is only used in conjunction with - *\*sampledataby*\*, *\*dailysummaryby*\*, - *\*annualdataby*\* and - *\*quarterlysummary_by_*\* functions). -* cedate (optional): (This parameter is only used in conjunction with - *\*sampledataby*\*, *\*dailysummaryby*\*, - *\*annualdataby*\* and - *\*quarterlysummary_by_*\* functions). -* return_header (optional): set to FALSE by default. -* duration (optional): (This parameter is only used in conjunction with - *\*sampledata_by_*\* functions). - -### Data Mart aggregate functions by Core Based Statistical Area (cbsa) -```{r bycbsafunctions, echo = FALSE, comment = NA} -by_cbsafunctions <- paste("._by_cbsa", sep = '|') - -str_subset(string = RAQSAPI_functions, pattern = by_cbsafunctions) %>% - cat(sep = " \n") -``` -functions in this family of functions aggregate data at the Core Based - Statistical Area (cbsa, as defined by the US Census Bureau) level. - All functions accept the following variables: - -* parameter: -* bdate: -* edate: -* cbsa_code: -* cbdate (optional): (This parameter is only used in conjunction with - *\*sampledata_by_*\*, *\*dailysummary_by_*\*, - *\*annualdata_by_*\* and - *\*quarterlysummary_by_*\* functions). -* cedate (optional): (This parameter is only used in conjunction with - *\*sampledata_by_*\*, *\*dailysummary_by_*\*, - *\*annualdata_by_*\* and - *\*quarterlysummary_by_*\* functions). -* return_header (optional): set to FALSE by default. -* duration (optional): (This parameter is only used in conjunction with - *\*sampledata_by_*\* functions). - - -### Data Mart aggregate functions by Primary Quality Assurance Organization (pqao) -```{r _by_pqaofunctions, echo = FALSE, comment = NA} -by_pqaofunctions <- paste("._by_pqao", sep = '|') - -str_subset(string = RAQSAPI_functions, pattern = by_pqaofunctions) %>% - cat(sep = " \n") -``` -functions in this family of functions aggregate data at the Primary Quality - Assurance Organization (pqao) level. All functions accept the following - variables: - -* parameter: -* bdate: -* edate: -* pqao_code: -* return_header (optional): set to FALSE by default. - -### Data Mart aggregate functions by latitude/longitude bounding box (_by_box) -```{r _by_BOXfunctions, echo = FALSE, comment = NA} -by_BOXfunctions <- paste("._by_box", sep = '|') - -str_subset(string = RAQSAPI_functions, pattern = by_BOXfunctions) %>% - cat(sep = " \n") -``` -Functions in this family of functions aggregate data by a - latitude/longitude bounding box (_by_box) level. All functions accept the - following variables: - -* parameter: -* bdate: -* edate: -* minlat: -* minlon: -* maxlon: -* maxlat: -* cbdate (optional): (This parameter is only used in conjunction with - *\*sampledata_by_*\*, *\*dailysummary_by_*\*, - *\*annualdata_by_*\* and - *\*quarterlysummary_by_*\* functions). -* cedate (optional): (This parameter is only used in conjunction with - *\*sampledata_by_*\*, *\*dailysummary_by_*\*, - *\*annualdata_by_*\* and - *\*quarterlysummary_by_*\* functions). -* return_header (optional): set to FALSE by default. -* duration (optional): (This parameter is only used in conjunction with - *\*sampledata_by_*\* functions). - -### Data Mart aggregate functions _by_state - -### RAQSAPI Miscellaneous functions -```{r misc, echo = FALSE, comment = NA} -misc_functions <- paste("aqs_removeheader", sep = '|') - -str_subset(string = RAQSAPI_functions, pattern = misc_functions) %>% - cat(sep = " \n") -``` -These are miscellaneous functions exported by RAQSAPI. - -RAQSAPI::aqs_removeheader is the function that the RAQSAPI library -uses internally to coerce an AQS_DATAMART_APIv2 S3 object into a tibble. -This is useful if the user saves the output from another RAQSAPI function -with return_header = TRUE set but later decides that they want just a -simple tibble object. This function takes only one variable: - -* AQSobject: diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/RAQSAPIPurpose.Rmd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/RAQSAPIPurpose.Rmd deleted file mode 100644 index 1e9070b..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/RAQSAPIPurpose.Rmd +++ /dev/null @@ -1,144 +0,0 @@ ---- -title: "RAQSAPI - Objectives of the RAQSAPI package" -author: -- affiliation: |- - "United States Environmental Protection Agency (US EPA), - Region III, - Air and Radiation Division, - Air Quality and Analysis Branch" - name: Clinton Mccrowey -output: - rmarkdown::html_vignette: default -bibliography: AQSAPI.bib -lang: en-US -#csl: acs-nano.csl -subtitle: RAQSAPI Purpose -abstract: RAQSAPI is an add-on package for the R programming language and - environment (hereafter referred to as simply "R") that connects R to a U.S. - EPA database for the retrieval of ambient air pollution data. This document - is intended to state the purpose of creating RAQSAPI. -vignette: > - %\VignetteIndexEntry{RAQSAPI - Objectives of the RAQSAPI package} - %\VignetteEncoding{UTF-8} - %\VignetteDepends{knitr} - %\VignetteDepends{rmarkdown} - %\VignetteEngine{knitr::rmarkdown} ---- - -```{r setup, include = FALSE} -knitr::opts_chunk$set( - collapse = TRUE, - comment = "#>" -) -``` -# The Air Quality System (AQS) -The Clean Air act [@cleanairact] requires all federal, state, local and tribal -air pollution control agencies monitor ambient air for concentrations of certain -air pollutants. Codified in 40 CFR Part 58 are the statutory requirements for -these monitoring programs, including monitoring network technical requirements, -operating schedules, data certification, data submittal and archiving -requirements. In addition to the required air pollution and meteorological -monitoring, pollution control agencies often perform additional and/or voluntary -air monitoring. - -* The three objectives of ambient air monitoring programs as stated in 40 CFR -Part 58 Appendix D.1 are as follows: - + Provide air pollution data to the public in a timely manner; - + Support compliance with ambient air quality standards and emissions - strategy development; and - + Support for air pollution research studies. - -As required by 40 CFR Part 58, air pollution and meteorological data is -submitted to the United States Environmental Protection Agency along with -associated metadata and quality assurance metadata via EPA's Air -Quality System (AQS)[@AboutAQSdata]. - -## About AQS Data Mart -AQS Data Mart is a publicly accessible mirror of data stored on the AQS database -designed to make air monitoring data more accessible and useful to the technical -community, scientific community and the general public. Data on AQS is copied to -AQS Data Mart once per week and this data is made available to the public -through web-based applications and APIs (application programming interface) -[@AQSDataMartWelcome]. RAQSAPI functions use the APIs provided by AQS Data Mart -to retrieve data. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -# Benefits of using RAQSAPI -RAQSAPI package for R is a easy to use R package that allows -anyone using the R programming environment to retrieve data from AQS Data Mart -Database vi the exposed API interface using a set of functions with consistent -input variables, function names and output structure. RAQSAPI does not require -installation of software or drivers external to R. The goal of RAQSAPI is to -make a package which eases retrieving of ambient air monitoring data from AQS -Data Mart. - -* Some possible uses of the RAQSAPI package - + Can be used as part of a monitoring agency's data validation process - + RAQSAPI can be used for data retrieval as part of quality management of air - data - + Ambient air monitoring data retrieval for Design value calculations - + To retrieve ambient air pollution concentrations - * Useful for retrieving ambient background air pollution data needed model - to perform air quality dispersion modeling - + Data retrieval for automation of Network Analysis - + Statistical analysis of ambient air data - + Compare ambient air pollution concentrations from different air monitoring - sites. - + Data retrieval to generate quarterly/audit reports - -# References diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/RAQSAPIusagetipsandprecautions.Rmd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/RAQSAPIusagetipsandprecautions.Rmd deleted file mode 100644 index e886bb7..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/RAQSAPIusagetipsandprecautions.Rmd +++ /dev/null @@ -1,60 +0,0 @@ ---- -title: RAQSAPI - Usage tips and precautions -author: Clinton Mccrowey physical scientist - US EPA -output: - rmarkdown::html_vignette: default -vignette: > - %\VignetteIndexEntry{RAQSAPI - Usage tips and precautions} - %\VignetteEncoding{UTF-8} - %\VignetteDepends{knitr} - %\VignetteDepends{rmarkdown} - %\VignetteEngine{knitr::rmarkdown} ---- - -## Usage tips and precautions -This section contains suggestions for completing certain data related tasks. - -* Determine if or how much data exists for a time-parameter-geography - combination: - + Retrieve data using the annualdata service. - + If no records are returned, we do not have the data. - + If records are returned, use the observation count to determine the - temporal and geographic distribution of the data. -* Monthly averages: - + AQS does not routinely calculate monthly aggregate statistics. - + If you need these, you must calculate them yourself. - + These can be calculated from the sample data or the daily data without - loss of fidelity. -* Determine a single value for a site with collocated monitors: - + Many sites will have collocated monitors - monitors collecting the same - parameter at the same time. - + The API currently provides only monitor level values. (site-level values - will be added in the future.) - + For some criteria pollutants (PM2.5, ozone, lead, and NO2), the - regulations define procedures for defining a single site-level value. - + For other pollutants, determining a single site-level value is left to - the investigator. - -* __Please adhere to the following when using the AQS Data Mart API__: - + __Limit the size of queries__. The AQS Data Mart contains billions of values - and you may request more than you intend. If you are unsure of the - amount of data, start small and work your way up. Please limit - queries to 1,000,000 rows of data each. You can use the - "observation count" field on the annualdata service to determine how - much data exists for a time-parameter-geography combination. - + __Limit the frequency of queries__. The AQS Data Mart can process a limited - load. Please wait for one request to complete before submitting another - and do not make more than 10 requests per minute. - + Be advised that RAQSAPI is capable of retrieving results for multiple - pollutants, this can result in the amount of data being returned being - multiplied by the number of pollutants being requested. - + Be advised that the AQS Data Mart API limits certain data requests to one - year of data at a time with the exception of the Monitor service. In order - to retrieve multiple years of data for these functions the RAQSAPI library - conveniently sends multiple API requests to the Data Mart API server, one - request for each year, this can result in the amount of data being returned - being multiplied by the number of years of data being requested. - -__The AQS Data Mart administrators may disable accounts without notice for -failure to adhere to these terms (Though they will contact the offending -user via the email address provided)__ diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/RAQSAPIvignette.Rmd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/RAQSAPIvignette.Rmd deleted file mode 100644 index 3a3562f..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/RAQSAPIvignette.Rmd +++ /dev/null @@ -1,74 +0,0 @@ ---- -title: Introduction to the RAQSAPI package -author: -- affiliation: |- - United States Environmental Protection Agency (US EPA), - Region III, - Air and Radiation Division, - Air Quality and Analysis Branch - name: Clinton Mccrowey -abstract: RAQSAPI is a package for R that connects the R programming language - environment to the United States Environmental Protection Agency's (US EPA) - Air Quality System (AQS) Data Mart database API for retrieval of ambient - air pollution data. -output: - rmarkdown::html_vignette: default -vignette: > - %\VignetteIndexEntry{Introduction to the RAQSAPI package} - %\VignetteEncoding{UTF-8} - %\VignetteKeyword{R} - %\VignetteKeyword{AQS} - %\VignetteKeyword{EPA} - %\VignetteKeyword{Data Mart} - %\VignetteKeyword{API} - %\VignetteDepends{magrittr} - %\VignetteDepends{stringr} - %\VignetteDepends{tibble} - %\VignetteDepends{purrr} - %\VignetteDepends{knitr} - %\VignetteDepends{rmarkdown} - %\VignetteDepends{RAQSAPI} - %\VignetteEngine{knitr::rmarkdown} -bibliography: AQSAPI.bib -csl: acs-nano.csl ---- - -```{r SETUP, echo = FALSE, message = FALSE, warning = FALSE} -invisible(library(glue, warn.conflicts = FALSE, quietly = TRUE)) - -#usethisurl <- "https://usethis.r-lib.org" -#usethissetup <- "/articles/articles/usethis-setup.html" -#usethispatsection <- "#get-and-store-a-github-personal-access-token" - -#patsetuplink <- glue::glue("{usethisurl}{usethissetup}{usethispatsection}") -``` -RAQSAPI hexsticker - -```{r child = "EPA_Disclaimer.Rmd", echo = FALSE, comment = NA} -``` - -```{r child = "Intro.Rmd", echo = FALSE, comment = NA} -``` - -```{r child = "TimelinessofAQSData.Rmd"} -``` - -```{r child = "InstallandSetup.Rmd", echo = FALSE} -``` - -```{r child = "UsingRAQSAPI.Rmd", echo = FALSE} -``` - -```{r child = "RAQSAPIusagetipsandprecautions.Rmd", echo = FALSE} -``` - -```{r child = "RAQSAPIFunctions-Long.Rmd", echo = FALSE} -``` - -```{r child = "Troubleshooting.Rmd", echo = FALSE} -``` - -```{r child = "Acknowledgements.Rmd", echo = FALSE} -``` - -# References diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/TimelinessofAQSData.Rmd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/TimelinessofAQSData.Rmd deleted file mode 100644 index 1e6d21e..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/TimelinessofAQSData.Rmd +++ /dev/null @@ -1,20 +0,0 @@ ---- -title: RAQSAPI - About the timeliness of AQS Data -author: Clinton Mccrowey physical scientist - US EPA -output: - rmarkdown::html_vignette: default -vignette: > - %\VignetteIndexEntry{RAQSAPI - About the timeliness of AQS Data} - %\VignetteEncoding{UTF-8} - %\VignetteDepends{knitr} - %\VignetteDepends{rmarkdown} - %\VignetteEngine{knitr::rmarkdown} ---- - -# About the timeliness of AQS Data - -EPA's AQS Datamart API, the service that RAQSAPI retrieves data from, does not -host real time (collected now/today) data. If real time data is needed, please -use the AirNow API and direct all questions toward real time data there. RAQSAPI -does not work with AirNow and cannot retrieve real time data. For more details -see section 7.1 of the About AQS Data page[@AboutAQSdata]. diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/Troubleshooting.Rmd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/Troubleshooting.Rmd deleted file mode 100644 index 7cf6149..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/Troubleshooting.Rmd +++ /dev/null @@ -1,29 +0,0 @@ ---- -title: RAQSAPI - Troubleshooting RAQSAPI -author: Clinton Mccrowey physical scientist - US EPA -output: - rmarkdown::html_vignette: default -vignette: > - %\VignetteIndexEntry{RAQSAPI - Troubleshooting RAQSAPI} - %\VignetteEncoding{UTF-8} - %\VignetteDepends{knitr} - %\VignetteDepends{rmarkdown} - %\VignetteEngine{knitr::rmarkdown} ---- - -# Troubleshooting - -parameters must be supplied exactly as they are specified, for example the -stateFIPS for Alabama is "01", entering a value of "1" for the stateFIPS -may lead to unexpected results. Do not omit leading zeros in parameters that -expect them. - -In Functions that have the return_header=TRUE option set the returned object is -an AQSAPI_v2 object, this is a 2 item list where the first object is a tibble -with the label \$Header, the second, a tibble with the label \$Data. sampledata -functions are limited by the API to one calendar year of data per API call so if -the user requests multiple years of data the sampledata call will return multiple -AQSAPI_v2 objects, one for each call to the API. The returned result is a list -of AQSAPI_v2 objects. In R to access the data in each item in the list the user -will need to use the "double bracket operator" ("[[", "]]") not the single -bracket operator ("[", "]"). diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/UsingRAQSAPI.Rmd b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/UsingRAQSAPI.Rmd deleted file mode 100644 index 8f7679f..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/UsingRAQSAPI.Rmd +++ /dev/null @@ -1,125 +0,0 @@ ---- -title: "RAQSAPI - Using RAQSAPI" -author: "Clinton Mccrowey physical scientist - US EPA" -date: "April 5, 2021" -output: - rmarkdown::html_vignette: default -vignette: > - %\VignetteIndexEntry{RAQSAPI - Using RAQSAPI} - %\VignetteEncoding{UTF-8} - %\VignetteDepends{knitr} - %\VignetteDepends{rmarkdown} - %\VignetteEngine{knitr::rmarkdown} ---- - -# Using The RAQSAPI library - -## Load RAQSAPI - after successfully installing the `RAQSAPI` package, load the `RAQSAPI` - library: - -```R -library(RAQSAPI) -``` - -## Sign up and setting up user credentials with the RAQSAPI library - -If you have not already done so you will need to sign up with AQS Data Mart - using aqs_sign_up function, ^[Use "?aqs_sign_up" after the RAQSAPI library has - been loaded to see the full usage description of the aqs_sign_up - function.] this function takes one input, "email", which is a R - character object, that represents the email address that you want to use - as a user credential to the AQS Data Mart service. After a successful call to - aqs_sign_up an email message will be sent to the email address provided - with a new Data Mart key which will be used as a credential key to access the - Data Mart API. The aqs_sign_up function can also be used to regenerate a - new key for an existing user, to generate a new key simply call the - aqs_sign_up function with the parameter "email" set to an existing - account. A new key will be e-mailed to the account given. - -The credentials used to access the Data Mart API service are stored in a R - environment variable that needs to be set every time the `RAQSAPI` library is - attached or the key is changed. Without valid credentials, the Data Mart - server will reject any request sent to it. The key used with Data Mart is a - key and is not a password, so the RAQSAPI library does not treat the key as a - password; this means that the key is stored in plain text and there are no - attempts to encrypt Data Mart credentials as would be done for a username and - password combination. The key that is supplied to use with Data Mart is not - intended for authentication but only account monitoring. Each time RAQSAPI is - loaded and before using any of it's functions use the aqs_credentials ^[Use - "?aqs_credentials" after the RAQSAPI library has been loaded to see the full - usage description of the aqs_credentials function.] function - to enter in the user credentials so that RAQSAPI can access the AQS Data Mart - server. - -| Note: The credentials used to access AQS Data Mart \ -API is not the same as the credentials used to access AQS. AQS users who do \ -not have access to the AQS Data Mart will need to create new credentials. \ - | -| -- | - - -## (suggested) Use the `keyring` package to manage credentials -It is highly suggested that users use a keyring manager to store and retrieve -their credentials while using RAQSAPI. One such credential manager is provided -by the `keyring` -package ^[[R `Keyring` package]https://cran.r-project.org/package=keyring)]. -The `Keyring` package uses the credential manager available for most popular -operating systems to store and manage user credentials. This will help avoid -hard coding credential information into R scripts. - -To use the `keyring` package with `RAQSAPI` first install `keyring`: - -```R -install.package("keyring") -``` - -Ensure that your system is supported by the `keyring` package before proceeding. - -```R - keyring::has_keyring_support() -``` - -then set the keyring used to access AQS Data Mart (make sure to replace the text -in the angled brackets with your specific user information): - -```R - library("keyring") - keyring::key_set(service = "AQSDatamart", - username = "\") -``` - -a popup window will appear for the user to input their keyring information. -Enter the AQS Data mart credential key associated with the AQS user name -provided, then hit enter. Now the AQS Data Mart user credential is set using -`keyring`. - -To retrieve the keyring to use with `RAQSAPI` load the `keyring` package and use -the function key_get to return the user credential to RAQSAPI: - -```R - library(RAQSAPI) - library(keyring) - datamartAPI_user <- \ - server <- "AQSDatamart" -``` - -then pass these variables to the aqs_credentials function when using RAQSAPI: - -```R - aqs_credentials(username = datamartAPI_user, - key = key_get(service = server, - username = datamartAPI_user - ) - ) -``` -To change the keyring stored with the `keyring` package repeat the steps above -to call the keyring::key_set function again with the new credential information. - -To retrieve a list of all keyrings managed with the `keyring` package use -the function: -> keyring::key_list() - -Refer the the[`keyring` package documentation]( -https://cran.r-project.org/package=keyring/readme/README.html) -for an in depth explanation on using the `keyring` package. diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/acs-nano.csl b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/acs-nano.csl deleted file mode 100644 index 17c71ed..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/acs-nano.csl +++ /dev/null @@ -1,18 +0,0 @@ - - diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/american-chemical-society.csl b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/american-chemical-society.csl deleted file mode 100644 index e428327..0000000 --- a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/american-chemical-society.csl +++ /dev/null @@ -1,279 +0,0 @@ - - diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/figures/AQS_LOGO.png b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/figures/AQS_LOGO.png deleted file mode 100644 index 0382bbe..0000000 Binary files a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/figures/AQS_LOGO.png and /dev/null differ diff --git a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/figures/RAQSAPIhexsticker.png b/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/figures/RAQSAPIhexsticker.png deleted file mode 100644 index b54d773..0000000 Binary files a/RAQSAPI.Rcheck/00_pkg_src/RAQSAPI/vignettes/figures/RAQSAPIhexsticker.png and /dev/null differ diff --git a/RAQSAPI.Rcheck/RAQSAPI-Ex.R b/RAQSAPI.Rcheck/RAQSAPI-Ex.R deleted file mode 100644 index f9fe16c..0000000 --- a/RAQSAPI.Rcheck/RAQSAPI-Ex.R +++ /dev/null @@ -1,2581 +0,0 @@ -pkgname <- "RAQSAPI" -source(file.path(R.home("share"), "R", "examples-header.R")) -options(warn = 1) -options(pager = "console") -base::assign(".ExTimings", "RAQSAPI-Ex.timings", pos = 'CheckExEnv') -base::cat("name\tuser\tsystem\telapsed\n", file=base::get(".ExTimings", pos = 'CheckExEnv')) -base::assign(".format_ptime", -function(x) { - if(!is.na(x[4L])) x[1L] <- x[1L] + x[4L] - if(!is.na(x[5L])) x[2L] <- x[2L] + x[5L] - options(OutDec = '.') - format(x[1L:3L], digits = 7L) -}, -pos = 'CheckExEnv') - -### * -library('RAQSAPI') - -base::assign(".oldSearch", base::search(), pos = 'CheckExEnv') -base::assign(".old_wd", base::getwd(), pos = 'CheckExEnv') -cleanEx() -nameEx("aqs_annualsummary_by_box") -### * aqs_annualsummary_by_box - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_annualsummary_by_box -### Title: aqs_annualsummary_by_box -### Aliases: aqs_annualsummary_by_box - -### ** Examples - -# Returns a tibble containing ozone annual summaries - # in the vicinity of central Alabama for the first two days - # of May, 2015 - ## Not run: -##D aqs_annualsummary_by_box(parameter = "44201", -##D bdate = as.Date("20150501", -##D format = "%Y%m%d"), -##D edate = as.Date("20170502", -##D format = "%Y%m%d"), -##D minlat = "33.3", -##D maxlat = "33.6", -##D minlon = "-87.0", -##D maxlon = "-86.7" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_annualsummary_by_box", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_annualsummary_by_cbsa") -### * aqs_annualsummary_by_cbsa - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_annualsummary_by_cbsa -### Title: aqs_annualsummary_by_cbsa -### Aliases: aqs_annualsummary_by_cbsa - -### ** Examples - -# Returns a tibble of annual summary $NO_{2}$ - # data the for Charlotte-Concord-Gastonia, NC cbsa on - # Janurary 01, 2017 - ## Not run: -##D aqs_annualsummary_by_cbsa(parameter = "42602", -##D bdate = as.Date("20170101", -##D format = "%Y%m%d" -##D ), -##D edate = as.Date("20170101", -##D format = "%Y%m%d" -##D ), -##D cbsa_code = "16740" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_annualsummary_by_cbsa", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_annualsummary_by_county") -### * aqs_annualsummary_by_county - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_annualsummary_by_county -### Title: aqs_annualsummary_by_county -### Aliases: aqs_annualsummary_by_county - -### ** Examples - -# returns an aqs S3 object with annual summary FRM/FEM - # PM2.5 data for Wake County, NC between January - # and February 2016 - ## Not run: -##D aqs_annualsummary_by_county(parameter = "88101", -##D bdate = as.Date("20160101", -##D format = "%Y%m%d"), -##D edate = as.Date("20180228", -##D format = "%Y%m%d"), -##D stateFIPS = "37", -##D countycode = "183" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_annualsummary_by_county", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_annualsummary_by_site") -### * aqs_annualsummary_by_site - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_annualsummary_by_site -### Title: aqs_annualsummary_by_site -### Aliases: aqs_annualsummary_by_site - -### ** Examples - -# Returns a tibble of annual summary ozone - # data for the Millbrook School site (\#0014) in Wake County, - # NC for 2017 (Note, for annual data, only the - # year portion of the bdate and edate are used and only whole - # years of data are returned. For example, bdate = 2017-12-31 and - # edate = 2018-01-01 will return full data for 2017 and 2018 ) - ## Not run: -##D aqs_annualsummary_by_site(parameter = "44201", -##D bdate = as.Date("20170618", -##D format="%Y%m%d"), -##D edate = as.Date("20190618", -##D format="%Y%m%d"), -##D stateFIPS = "37", -##D countycode = "183", -##D sitenum = "0014" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_annualsummary_by_site", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_annualsummary_by_state") -### * aqs_annualsummary_by_state - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_annualsummary_by_state -### Title: aqs_annualsummary_by_state -### Aliases: aqs_annualsummary_by_state - -### ** Examples - -# returns a tibble of all benzene annualy - # summaries from North Carolina collected for 1995 - ## Not run: -##D aqs_annualsummary_by_state(parameter = "45201", -##D bdate = as.Date("19950515", -##D format="%Y%m%d" -##D ), -##D edate = as.Date("19950515", -##D format = "%Y%m%d" -##D ), -##D stateFIPS = "37" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_annualsummary_by_state", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_cbsas") -### * aqs_cbsas - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_cbsas -### Title: aqs_cbsas -### Aliases: aqs_cbsas - -### ** Examples - -# Returns a tibble of Core Based Statistical Areas (cbsas) - # and their respective cbsa codes - ## Not run: aqs_cbsas() - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_cbsas", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_classes") -### * aqs_classes - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_classes -### Title: aqs_classes -### Aliases: aqs_classes - -### ** Examples - -# Returns a tibble of parameter classes (groups of parameters, i.e. - # "criteria" or all") - ## Not run: aqs_classes() - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_classes", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_counties_by_state") -### * aqs_counties_by_state - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_counties_by_state -### Title: aqs_counties_by_state -### Aliases: aqs_counties_by_state - -### ** Examples - - # Returns a tibble all the counties - # in North Carolina the county FIPS codes (county codes) for - # each. - ## Not run: aqs_counties_by_state(stateFIPS = "37") - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_counties_by_state", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_credentials") -### * aqs_credentials - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_credentials -### Title: aqs_credentials -### Aliases: aqs_credentials - -### ** Examples - - #to authenticate an existing user the email address - # "John.Doe@myemail.com" and key = "MyKey" - # after calling this function please follow the instructions that are sent - # in the verification e-mail before proceeding. - ## Not run: -##D aqs_credentials(username = "John.Doe@myemail.com", -##D key = "MyKey") -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_credentials", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_dailysummary_by_box") -### * aqs_dailysummary_by_box - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_dailysummary_by_box -### Title: aqs_dailysummary_by_box -### Aliases: aqs_dailysummary_by_box - -### ** Examples - -#Returns a tibble of ozone daily summaries in the vicinity of - # central Alabama for the first two days of May 2015 - - ## Not run: -##D aqs_dailysummary_by_box(parameter = "44201", -##D bdate = as.Date("20140501", -##D format = "%Y%m%d" -##D ), -##D edate = as.Date("20160502", -##D format = "%Y%m%d" -##D ), -##D mqinlat ="33.3", -##D maxlat = "33.6", -##D minlon = "-87.0", -##D maxlon = "-86.7" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_dailysummary_by_box", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_dailysummary_by_cbsa") -### * aqs_dailysummary_by_cbsa - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_dailysummary_by_cbsa -### Title: aqs_dailysummary_by_cbsa -### Aliases: aqs_dailysummary_by_cbsa - -### ** Examples - -# Returns a tibble of $NO_{2}$ daily summary - # data the for Charlotte-Concord-Gastonia, NC cbsa on - # Janurary 01, 2017 - ## Not run: -##D aqs_dailysummary_by_cbsa(parameter = "42602", -##D bdate = as.Date("20170101", -##D format = "%Y%m%d" -##D ), -##D edate = as.Date("20190101", -##D format = "%Y%m%d" -##D ), -##D cbsa_code = "16740" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_dailysummary_by_cbsa", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_dailysummary_by_county") -### * aqs_dailysummary_by_county - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_dailysummary_by_county -### Title: aqs_dailysummary_by_county -### Aliases: aqs_dailysummary_by_county - -### ** Examples - -# returns an aqs S3 object of daily summary FRM/FEM PM2.5 data - # for Wake County, NC between January and February 2016 - ## Not run: -##D aqs_dailysummary_by_county(parameter = "88101", -##D bdate = as.Date("20160101", -##D format = "%Y%m%d"), -##D edate = as.Date("20170228", -##D format = "%Y%m%d"), -##D stateFIPS = "37", -##D countycode = "183" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_dailysummary_by_county", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_dailysummary_by_site") -### * aqs_dailysummary_by_site - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_dailysummary_by_site -### Title: aqs_dailysummary_by_site -### Aliases: aqs_dailysummary_by_site - -### ** Examples - -#Returns a tibble of daily summary ozone - # data for the Millbrook School site (\#0014) in Wake County, - # NC for June 18, 2017. - ## Not run: -##D aqs_dailysummary_by_site(parameter = "44201", -##D bdate = as.Date("20160618", -##D format = "%Y%m%d"), -##D edate = as.Date("20190618", -##D format = "%Y%m%d"), -##D stateFIPS = "37", -##D countycode = "183", -##D sitenum = "0014" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_dailysummary_by_site", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_dailysummary_by_state") -### * aqs_dailysummary_by_state - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_dailysummary_by_state -### Title: aqs_dailysummary_by_state -### Aliases: aqs_dailysummary_by_state - -### ** Examples - -# returns a tibble of all benzene daily - # summaries from North Carolina collected on May 15th, 1995 - ## Not run: -##D aqs_dailysummary_by_state(parameter = "45201", -##D bdate = as.Date("19950515", -##D format="%Y%m%d" -##D ), -##D edate = as.Date("19970515", -##D format = "%Y%m%d" -##D ), -##D stateFIPS = "37" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_dailysummary_by_state", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_fields_by_service") -### * aqs_fields_by_service - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_fields_by_service -### Title: aqs_fieldsbyservice -### Aliases: aqs_fields_by_service - -### ** Examples - -# Returns a tibble containing a list and definitions - # of fields in the Sample Data service - ## Not run: aqs_fieldsbyservice(service = "sampleData") - - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_fields_by_service", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_isavailable") -### * aqs_isavailable - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_isavailable -### Title: aqs_isavailable -### Aliases: aqs_isavailable - -### ** Examples - - # Check if the AQS API is up, running and accepting requests. - ## Not run: aqs_isAvailable() - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_isavailable", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_knownissues") -### * aqs_knownissues - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_knownissues -### Title: aqs_knownissues -### Aliases: aqs_knownissues - -### ** Examples - - # Retrieve a tibble of known issues directly from the AQS data mart API - ## Not run: aqs_knownissues() - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_knownissues", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_mas") -### * aqs_mas - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_mas -### Title: aqs_mas -### Aliases: aqs_mas - -### ** Examples - -# Returns a tibble or an AQS_Data Mart_APIv2 S3 object - # of monitoring agencies and their respective - # monitoring agency codes. - ## Not run: aqs_mas() - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_mas", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_monitors_by_box") -### * aqs_monitors_by_box - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_monitors_by_box -### Title: aqs_monitors_by_box -### Aliases: aqs_monitors_by_box - -### ** Examples - -# Returns a tibble of all ozone - # monitors in the vicinity of central Alabama that operated in - # 1995 - ## Not run: -##D aqs_monitors_by_box(parameter="44201", -##D bdate=as.Date("19950101", -##D format="%Y%m%d"), -##D edate=as.Date("19951231", -##D format="%Y%m%d"), -##D minlat="33.3", -##D maxlat="33.6", -##D minlon="-87.0", -##D maxlon="-86.7" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_monitors_by_box", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_monitors_by_cbsa") -### * aqs_monitors_by_cbsa - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_monitors_by_cbsa -### Title: aqs_monitors_by_cbsa -### Aliases: aqs_monitors_by_cbsa - -### ** Examples - -# returns a tibble of $NO_{2}$ monitors - # for Charlotte-Concord-Gastonia, NC cbsa that were operating - # on Janurary 01, 2017 - ## Not run: -##D aqs_monitors_by_cbsa(parameter="42602", -##D bdate=as.Date("20170101", -##D format="%Y%m%d"), -##D edate=as.Date("20170101", -##D format="%Y%m%d"), -##D cbsa_code="16740" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_monitors_by_cbsa", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_monitors_by_county") -### * aqs_monitors_by_county - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_monitors_by_county -### Title: aqs_monitors_by_county -### Aliases: aqs_monitors_by_county - -### ** Examples - -# returns an aqs_v2 S3 object containing all SO2 monitors in - # Hawaii County, HI that were operating between May 01-02, 2015. - ## Not run: -##D aqs_monitors_by_county(parameter="42401", -##D bdate=as.Date("20150501", format="%Y%m%d"), -##D edate=as.Date("20150502", format="%Y%m%d"), -##D stateFIPS="15", -##D countycode="001" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_monitors_by_county", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_monitors_by_site") -### * aqs_monitors_by_site - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_monitors_by_site -### Title: aqs_monitors_by_site -### Aliases: aqs_monitors_by_site - -### ** Examples - - #Returns a tibble of the SO2 monitors at Hawaii - # Volcanoes NP site (\#0007) in Hawaii County, HI that were operating - # between May 1 , 2015-2019. (Note, all monitors that operated between the - # bdate and edate will be returned). - ## Not run: -##D aqs_monitors_by_site(parameter = "42401", -##D bdate = as.Date("20150501", -##D format="%Y%m%d"), -##D edate = as.Date("20190501", -##D format="%Y%m%d"), -##D stateFIPS = "15", -##D countycode = "001", -##D sitenum = "0007" -##D ) -##D -## End(Not run) - - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_monitors_by_site", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_monitors_by_state") -### * aqs_monitors_by_state - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_monitors_by_state -### Title: aqs_monitors_by_state -### Aliases: aqs_monitors_by_state - -### ** Examples - -# returns a tibble of SO2 monitors in Hawaii - # that were operating on May 01, 2017 - ## Not run: -##D aqs_monitors_by_state(parameter="88101", -##D bdate=as.Date("20170101", -##D format="%Y%m%d"), -##D edate=as.Date("20171231", -##D format="%Y%m%d"), -##D stateFIPS="01" -##D ) -##D -## End(Not run) - - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_monitors_by_state", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_parameters_by_class") -### * aqs_parameters_by_class - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_parameters_by_class -### Title: aqs_parameters_by_class -### Aliases: aqs_parameters_by_class - -### ** Examples - -# Returns a tibble of AQS parameters in the criteria class - ## Not run: aqs_parameters_by_class(class = "CRITERIA") - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_parameters_by_class", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_pqaos") -### * aqs_pqaos - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_pqaos -### Title: aqs_pqaos -### Aliases: aqs_pqaos - -### ** Examples - -# Returns a tibble of primary quality assurance - # organizations (pqaos) - ## Not run: aqs_pqaos() - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_pqaos", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_annualperformanceeval_by_MA") -### * aqs_qa_annualperformanceeval_by_MA - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_annualperformanceeval_by_MA -### Title: aqs_qa_annualperformanceeval_by_MA -### Aliases: aqs_qa_annualperformanceeval_by_MA - -### ** Examples - - # Returns a tibble containing annual performance evaluation data - # for ozone where the monitoring agency is the Alabama Department - # of Environmental Management (MA_code 0013). - ## Not run: -##D aqs_qa_annualperformanceeval_by_MA(parameter = "44201", -##D bdate = as.Date("20170101", -##D format = "%Y%m%d"), -##D edate = as.Date("20171231", -##D format = "%Y%m%d"), -##D MA_code = "0013" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_annualperformanceeval_by_MA", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_annualperformanceeval_by_county") -### * aqs_qa_annualperformanceeval_by_county - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_annualperformanceeval_by_county -### Title: aqs_qa_annualperformanceeval_by_county -### Aliases: aqs_qa_annualperformanceeval_by_county - -### ** Examples - -# Returns a tibble containing annual performance evaluation data - # (raw) for ozone in Baldwin County, AL for 2017 in RD format. - ## Not run: -##D aqs_qa_annualperformanceeval_by_county(parameter = "44201", -##D bdate = as.Date("20170101", -##D format = "%Y%m%d"), -##D edate = as.Date("20171231", -##D format = "%Y%m%d"), -##D stateFIPS = "01", -##D countycode = "003" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_annualperformanceeval_by_county", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_annualperformanceeval_by_pqao") -### * aqs_qa_annualperformanceeval_by_pqao - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_annualperformanceeval_by_pqao -### Title: aqs_qa_annualperformanceeval_by_pqao -### Aliases: aqs_qa_annualperformanceeval_by_pqao - -### ** Examples - -# Returns a tibble containing annual performance evaluation data - # for ozone where the PQAO is the Alabamaba Department of - # Environmental Management (pqao_code 0013). - ## Not run: -##D aqs_qa_annualperformanceeval_by_pqao(parameter = "44201", -##D bdate = as.Date("20170101", -##D format = "%Y%m%d"), -##D edate = as.Date("20171231", -##D format = "%Y%m%d"), -##D pqao_code = "0013" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_annualperformanceeval_by_pqao", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_annualperformanceeval_by_site") -### * aqs_qa_annualperformanceeval_by_site - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_annualperformanceeval_by_site -### Title: aqs_qa_annualperformanceeval_by_site -### Aliases: aqs_qa_annualperformanceeval_by_site - -### ** Examples - -#Returns a tibble containing annual performance evaluation data for - # ozone at the Fairhope site in Baldwin County, AL for 2017 - ## Not run: -##D aqs_qa_annualperformanceeval_by_site(parameter = "44201", -##D bdate = as.Date("20170101", -##D format = "%Y%m%d"), -##D edate = as.Date("20171231", -##D format = "%Y%m%d"), -##D stateFIPS = "01", -##D countycode = "003", -##D sitenum = "0010" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_annualperformanceeval_by_site", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_annualperformanceeval_by_state") -### * aqs_qa_annualperformanceeval_by_state - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_annualperformanceeval_by_state -### Title: aqs_qa_annualperformanceeval_by_state -### Aliases: aqs_qa_annualperformanceeval_by_state - -### ** Examples - -# Returns a tibble containing annual performance evaluation - # data for ozone in Alabamba for 2017. - ## Not run: -##D aqs_qa_annualperformanceeval_by_state(parameter = "44201", -##D bdate = as.Date("20170101", -##D format = "%Y%m%d"), -##D edate = as.Date("20171231", -##D format = "%Y%m%d"), -##D stateFIPS = "01" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_annualperformanceeval_by_state", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_annualperformanceevaltransaction_by_MA") -### * aqs_qa_annualperformanceevaltransaction_by_MA - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_annualperformanceevaltransaction_by_MA -### Title: aqs_qa_annualperformanceevaltransaction_by_MA -### Aliases: aqs_qa_annualperformanceevaltransaction_by_MA - -### ** Examples - -# Returns a tibble containing annual performance evaluation data - # for ozone in where the MA is the Alabama Department of - # Environmental Management (MA_code 0013) for 2017 in RD format. - ## Not run: -##D aqs_qa_annualperformanceevaltransaction_by_MA(parameter = "44201", -##D bdate = as.Date("20170101", -##D format = "%Y%m%d"), -##D edate = as.Date("20171231", -##D format = "%Y%m%d"), -##D MA_code = "0013" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_annualperformanceevaltransaction_by_MA", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_annualperformanceevaltransaction_by_county") -### * aqs_qa_annualperformanceevaltransaction_by_county - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_annualperformanceevaltransaction_by_county -### Title: aqs_qa_annualperformanceevaltransaction_by_site -### Aliases: aqs_qa_annualperformanceevaltransaction_by_county - -### ** Examples - -# Returns a tibble containing annual performance evaluation data - # (raw) for ozone in Baldwin County, AL for 2017 in RD format. - ## Not run: -##D aqs_qa_annualperformanceevaltransaction_by_county(parameter = "44201", -##D bdate = as.Date("20170101", -##D format = "%Y%m%d"), -##D edate = as.Date("20171231", -##D format = "%Y%m%d"), -##D stateFIPS = "01", -##D countycode = "003" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_annualperformanceevaltransaction_by_county", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_annualperformanceevaltransaction_by_pqao") -### * aqs_qa_annualperformanceevaltransaction_by_pqao - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_annualperformanceevaltransaction_by_pqao -### Title: aqs_qa_annualperformanceevaltransaction_by_pqao -### Aliases: aqs_qa_annualperformanceevaltransaction_by_pqao - -### ** Examples - -#Returns a tibble containing annual performance evaluation data for - # ozone in where the PQAO is the Alabama Department of - # Environmental Management (pqao_code 0013) for 2017 in RD format. - ## Not run: -##D aqs_qa_annualperformanceevaltransaction_by_pqao(parameter = -##D "44201", -##D bdate = as.Date("20170101", -##D format = "%Y%m%d"), -##D edate = as.Date("20171231", -##D format = "%Y%m%d"), -##D pqao_code = "0013" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_annualperformanceevaltransaction_by_pqao", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_annualperformanceevaltransaction_by_site") -### * aqs_qa_annualperformanceevaltransaction_by_site - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_annualperformanceevaltransaction_by_site -### Title: aqs_qa_annualperformanceevaltransaction_by_site -### Aliases: aqs_qa_annualperformanceevaltransaction_by_site - -### ** Examples - -#Returns a tibble containing annual performance evaluation data - # (raw) for ozone at the Fairhope site in Baldwin County, AL for - # 2017 in RD format. -## Not run: -##D aqs_qa_annualperformanceevaltransaction_by_site(parameter = "44201", -##D bdate = as.Date("20170101", -##D format = "%Y%m%d"), -##D edate = as.Date("20171231", -##D format = "%Y%m%d"), -##D stateFIPS = "01", -##D countycode = "003", -##D sitenum = "0010" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_annualperformanceevaltransaction_by_site", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_annualperformanceevaltransaction_by_state") -### * aqs_qa_annualperformanceevaltransaction_by_state - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_annualperformanceevaltransaction_by_state -### Title: aqs_qa_annualperformanceevaltransaction_by_state -### Aliases: aqs_qa_annualperformanceevaltransaction_by_state - -### ** Examples - -# Returns a tibble containing annual performance evaluation data - # for ozone in Alabmba for 2017 in RD format. -## Not run: -##D aqs_qa_annualperformanceevaltransaction_by_state(parameter = "44201", -##D bdate = as.Date("20170101", -##D format = "%Y%m%d"), -##D edate = as.Date("20171231", -##D format = "%Y%m%d") -##D stateFIPS = "01" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_annualperformanceevaltransaction_by_state", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_blanks_by_MA") -### * aqs_qa_blanks_by_MA - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_blanks_by_MA -### Title: aqs_qa_blanks_by_MA -### Aliases: aqs_qa_blanks_by_MA - -### ** Examples - -# Returns a tibble containing PM2.5 blank data in - # January 2018 where the Monitoring Agency is the Alabama - # Department of Environmental Management (agency 0013) - ## Not run: -##D aqs_qa_blanks_by_MA(parameter = "88101", -##D bdate = as.Date("20170101", -##D format = "%Y%m%d"), -##D edate = as.Date("20190131", -##D format = "%Y%m%d"), -##D MA_code = "0013" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_blanks_by_MA", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_blanks_by_county") -### * aqs_qa_blanks_by_county - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_blanks_by_county -### Title: aqs_qa_blanks_by_county -### Aliases: aqs_qa_blanks_by_county - -### ** Examples - -# returns a tibble with PM2.5 blank data for - # Colbert County, AL for January 2018 - ## Not run: -##D aqs_qa_blanks_by_county(parameter = "88101", -##D bdate = as.Date("20170101", -##D format="%Y%m%d"), -##D edate = as.Date("20190131", -##D format="%Y%m%d"), -##D stateFIPS = "01", -##D countycode = "033" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_blanks_by_county", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_blanks_by_pqao") -### * aqs_qa_blanks_by_pqao - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_blanks_by_pqao -### Title: aqs_qa_blanks_by_pqao -### Aliases: aqs_qa_blanks_by_pqao - -### ** Examples - -# Returns tibble of PM2.5 blank data in - # January 2018 where the PQAO is the Alabama Department of - # Environmental Management (agency 0013) - ## Not run: -##D aqs_qa_blanks_by_pqao(parameter = "88101", -##D bdate = as.Date("20180101", -##D format = "%Y%m%d"), -##D edate = as.Date("20180131", -##D format = "%Y%m%d"), -##D pqao_code = "0013" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_blanks_by_pqao", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_blanks_by_site") -### * aqs_qa_blanks_by_site - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_blanks_by_site -### Title: aqs_qa_blanks_by_site -### Aliases: aqs_qa_blanks_by_site - -### ** Examples - -#Returns a tibble of PM2.5 blank - # data for the Muscle Shoals site (#0014) in Colbert County, AL - # for January 2018 - ## Not run: -##D aqs_qa_blanks_by_site(parameter = "88101", -##D bdate = as.Date("20170101", -##D format="%Y%m%d"), -##D edate = as.Date("20190131", -##D format="%Y%m%d"), -##D stateFIPS = "01", -##D countycode = "033", -##D sitenum = "1002" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_blanks_by_site", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_blanks_by_state") -### * aqs_qa_blanks_by_state - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_blanks_by_state -### Title: aqs_qa_blanks_by_state -### Aliases: aqs_qa_blanks_by_state - -### ** Examples - -# returns a tibble which contains PM2.5 blank data - # for Alabama for January 2018 - ## Not run: -##D aqs_qa_blanks_by_state(parameter = "88101", -##D bdate = as.Date("20180101", -##D format = "%Y%m%d" -##D ), -##D edate = as.Date("20180131", -##D format = "%Y%m%d"), -##D stateFIPS = "01" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_blanks_by_state", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_collocated_assessments_by_MA") -### * aqs_qa_collocated_assessments_by_MA - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_collocated_assessments_by_MA -### Title: aqs_qa_collocated_assessments_by_MA -### Aliases: aqs_qa_collocated_assessments_by_MA - -### ** Examples - -# Returns a tibble containing collocated assessment - # data for FRM PM2.5 January 2013 where the Monitoring Agency is - # the Alabama Department of Environmental Management - # (agency 0013) - ## Not run: -##D aqs_qa_collocated_assessments_by_MA(parameter="88101", -##D bdate = as.Date("20130101", -##D format = "%Y%m%d"), -##D edate = as.Date("20150131", -##D format="%Y%m%d"), -##D MA_code = "0013" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_collocated_assessments_by_MA", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_collocated_assessments_by_county") -### * aqs_qa_collocated_assessments_by_county - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_collocated_assessments_by_county -### Title: aqs_qa_collocated_assessments_by_county -### Aliases: aqs_qa_collocated_assessments_by_county - -### ** Examples - -# Returns a tibble with collocated assessment data - # for FRM PM2.5 in Madison County, AL for January 2015 - ## Not run: -##D aqs_qa_collocated_assessments_by_county(parameter = "88101", -##D bdate = as.Date("20150101", -##D format = "%Y%m%d" -##D ), -##D edate = as.Date("20150131", -##D format = "%Y%m%d" -##D ), -##D stateFIPS = "01", -##D countycode = "089" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_collocated_assessments_by_county", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_collocated_assessments_by_pqao") -### * aqs_qa_collocated_assessments_by_pqao - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_collocated_assessments_by_pqao -### Title: aqs_qa_collocated_assessments_by_pqao -### Aliases: aqs_qa_collocated_assessments_by_pqao - -### ** Examples - -# Returns a tibble of collocated assessment - # data for FRM PM2.5 in January 2013 where the PQAO is the Alabama - # Department of Environmental Management (agency 0013) - ## Not run: -##D aqs_qa_collocated_assessments_by_pqao(parameter = "88101", -##D bdate = as.Date("20130101", -##D format = "%Y%m%d"), -##D edate = as.Date("20150131", -##D format = "%Y%m%d"), -##D pqao_code = "0013" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_collocated_assessments_by_pqao", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_collocated_assessments_by_site") -### * aqs_qa_collocated_assessments_by_site - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_collocated_assessments_by_site -### Title: aqs_qa_collocated_assessments_by_site -### Aliases: aqs_qa_collocated_assessments_by_site - -### ** Examples - -#returns a tibble of collocated assessment data - # for FRM PM2.5 at the Huntsville Old Airport site (\#0014) - # in Madison County, AL for January 2015: - ## Not run: -##D aqs_qa_collocated_assessments_by_site(parameter = "88101", -##D bdate = as.Date("20150101", -##D format = "%Y%m%d" -##D ), -##D edate = as.Date("20150131", -##D format = "%Y%m%d" -##D ), -##D stateFIPS = "01", -##D countycode = "089", -##D sitenum = "0014" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_collocated_assessments_by_site", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_collocated_assessments_by_state") -### * aqs_qa_collocated_assessments_by_state - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_collocated_assessments_by_state -### Title: aqs_qa_collocated_assessments_by_state -### Aliases: aqs_qa_collocated_assessments_by_state - -### ** Examples - -# returns a tibble of collocated - # assessment data for FRM2.5 for January 2013 - ## Not run: -##D aqs_qa_collocated_assessments_by_state(parameter="88101", -##D bdate = as.Date("20130101", -##D format = "%Y%m%d" -##D ), -##D edate = as.Date("20150131", -##D format = "%Y%m%d" -##D ), -##D stateFIPS = "01" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_collocated_assessments_by_state", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_flowrateaudit_by_MA") -### * aqs_qa_flowrateaudit_by_MA - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_flowrateaudit_by_MA -### Title: aqs_qa_flowrateaudit_by_MA -### Aliases: aqs_qa_flowrateaudit_by_MA - -### ** Examples - - # returns a tibble of flow rate audit data - # for FRM PM2.5 January 2016 - Januray 2018 where the Monitoring Agency is - # the Jefferson County, AL Department of Health (agency 0550) - ## Not run: -##D aqs_qa_flowrateaudit_by_MA(parameter = "88101", -##D bdate = as.Date("20160101", -##D format = "%Y%m%d"), -##D edate = as.Date("20180131", -##D format = "%Y%m%d"), -##D MA_code = "0550" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_flowrateaudit_by_MA", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_flowrateaudit_by_county") -### * aqs_qa_flowrateaudit_by_county - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_flowrateaudit_by_county -### Title: aqs_qa_flowrateaudit_by_county -### Aliases: aqs_qa_flowrateaudit_by_county - -### ** Examples - -#Returns a tibble of flow rate audit data for - # Jefferson County, AL for January 2018 - ## Not run: -##D aqs_qa_flowrateaudit_by_county(parameter = "88101", -##D bdate = as.Date("20170101", -##D format="%Y%m%d"), -##D edate = as.Date("20190131", -##D format = "%Y%m%d"), -##D tateFIPS = "01", -##D countycode = "073" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_flowrateaudit_by_county", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_flowrateaudit_by_pqao") -### * aqs_qa_flowrateaudit_by_pqao - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_flowrateaudit_by_pqao -### Title: aqs_qa_flowrateaudit_by_pqao -### Aliases: aqs_qa_flowrateaudit_by_pqao - -### ** Examples - -# Returns a tibble of flow rate audit data for January - # 2018 where the PQAO is the Jefferson County, AL Department of - # Health (agency 0550). - ## Not run: -##D aqs_qa_flowrateaudit_by_pqao(parameter = "88101", -##D bdate = as.Date("20170101", -##D format = "%Y%m%d"), -##D edate = as.Date("20180131", -##D format = "%Y%m%d"), -##D pqao_code = "0550" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_flowrateaudit_by_pqao", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_flowrateaudit_by_site") -### * aqs_qa_flowrateaudit_by_site - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_flowrateaudit_by_site -### Title: aqs_qa_flowrate audit_by_site -### Aliases: aqs_qa_flowrateaudit_by_site - -### ** Examples - -# returns a tibble of flow rate audit data - # for the Wylam site (#2003) in Jefferson County, AL - # for January 2018: - ## Not run: -##D aqs_qa_flowrateaudit_by_site(parameter = "88101", -##D bdate = as.Date("20150101", -##D format="%Y%m%d"), -##D edate = as.Date("20180131", -##D format="%Y%m%d"), -##D stateFIPS = "01", -##D countycode = "073", -##D sitenum = "2003" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_flowrateaudit_by_site", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_flowrateaudit_by_state") -### * aqs_qa_flowrateaudit_by_state - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_flowrateaudit_by_state -### Title: aqs_qa_flowrateaudit_by_state -### Aliases: aqs_qa_flowrateaudit_by_state - -### ** Examples - -# returns a tibble of flow rate audit - # data for Alabama in January 2018 - ## Not run: -##D aqs_qa_flowrateaudit_by_state(parameter = "88101", -##D bdate = as.Date("20170101", -##D format = "%Y%m%d"), -##D edate = as.Date("20180131", -##D format = "%Y%m%d"), -##D stateFIPS = "01" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_flowrateaudit_by_state", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_flowrateverification_by_MA") -### * aqs_qa_flowrateverification_by_MA - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_flowrateverification_by_MA -### Title: aqs_qa_flowrateverification_by_MA -### Aliases: aqs_qa_flowrateverification_by_MA - -### ** Examples - - # Returns a tibble containing collocated assessment - # data for FRM PM2.5 January 2013 where the Monitoring Agency is - # the Alabama Department of Environmental Management (agency 0013) - ## Not run: -##D aqs_qa_flowrateverification_by_MA(parameter = "88101", -##D bdate = as.Date("20130101", -##D format = "%Y%m%d" -##D ), -##D edate = as.Date("20150131", -##D format = "%Y%m%d" -##D ), -##D MA_code = "0013" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_flowrateverification_by_MA", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_flowrateverification_by_county") -### * aqs_qa_flowrateverification_by_county - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_flowrateverification_by_county -### Title: aqs_qa_flowrateverification_by_county -### Aliases: aqs_qa_flowrateverification_by_county - -### ** Examples - -# returns a tibble of flow rate verification data for - # Colbert County, AL for January 2018 - ## Not run: -##D aqs_qa_flowrateverification_by_county(parameter = "88101", -##D bdate = as.Date("20180101", -##D format = "%Y%m%d" -##D ), -##D edate = as.Date("20190131", -##D format = "%Y%m%d" -##D ), -##D stateFIPS = "01", -##D countycode = "033" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_flowrateverification_by_county", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_flowrateverification_by_pqao") -### * aqs_qa_flowrateverification_by_pqao - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_flowrateverification_by_pqao -### Title: aqs_qa_flowrateverification_by_pqao -### Aliases: aqs_qa_flowrateverification_by_pqao - -### ** Examples - -# returns a tibble of flow rate verification - # data for January 2018 where the PQAO is the Alabama Department - # of Environmental Management (agency 0013) - ## Not run: -##D aqs_qa_flowrateverification_by_pqao(parameter = "88101", -##D bdate = as.Date("20170101", -##D format = "%Y%m%d" -##D ), -##D edate = as.Date("20190131", -##D format = "%Y%m%d" -##D ), -##D pqao_code = "0013" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_flowrateverification_by_pqao", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_flowrateverification_by_site") -### * aqs_qa_flowrateverification_by_site - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_flowrateverification_by_site -### Title: aqs_qa_flowrateverification_by_site -### Aliases: aqs_qa_flowrateverification_by_site - -### ** Examples - -# returns a tibble of flow rate verification - # data for the Muscle Shoals site (#1002) in Colbert County, AL - # for January 2018: - ## Not run: -##D aqs_qa_flowrateverification_by_site(parameter = "88101", -##D bdate = as.Date("20170101", -##D format = "%Y%m%d"), -##D edate = as.Date("20180131", -##D format = "%Y%m%d"), -##D stateFIPS = "01", -##D countycode = "033", -##D sitenum = "1002" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_flowrateverification_by_site", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_flowrateverification_by_state") -### * aqs_qa_flowrateverification_by_state - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_flowrateverification_by_state -### Title: aqs_qa_flowrateverification_by_state -### Aliases: aqs_qa_flowrateverification_by_state - -### ** Examples - -# Returns a tibble of flow rate verification data for the state of - # Alabama for 2017-2019 - ## Not run: -##D aqs_qa_flowrateverification_by_state(parameter = "88101", -##D bdate = as.Date("20170101", -##D format = "%Y%m%d" -##D ), -##D edate = as.Date("20190131", -##D format="%Y%m%d" -##D ), -##D stateFIPS = "01" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_flowrateverification_by_state", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_one_point_qc_by_MA") -### * aqs_qa_one_point_qc_by_MA - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_one_point_qc_by_MA -### Title: aqs_qa_one_point_qc_by_MA -### Aliases: aqs_qa_one_point_qc_by_MA - -### ** Examples - -# returns a tibble of ozone One Point QC data - # in January 2018 where the Monitoring Agency is the - # Massachusetts Department of Environmental Protection - # (agency 0660) - ## Not run: -##D aqs_qa_one_point_qc_by_MA(parameter = "44201", -##D bdate = as.Date("20170101", -##D format = "%Y%m%d"), -##D edate = as.Date("20180131", -##D format = "%Y%m%d"), -##D MA_code = "0660" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_one_point_qc_by_MA", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_one_point_qc_by_county") -### * aqs_qa_one_point_qc_by_county - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_one_point_qc_by_county -### Title: aqs_qa_one_point_qc_by_county_ -### Aliases: aqs_qa_one_point_qc_by_county - -### ** Examples - -#returns a tibble of One Point QC data for ozone - # in Barnstable County, MA for January 2018 - ## Not run: -##D aqs_qa_one_point_qc_by_county(parameter= "44201", -##D bdate = as.Date("20170101", -##D format = "%Y%m%d"), -##D edate = a s.Date("20180131", -##D format = "%Y%m%d"), -##D stateFIPS = "25", -##D countycode = "001" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_one_point_qc_by_county", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_one_point_qc_by_pqao") -### * aqs_qa_one_point_qc_by_pqao - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_one_point_qc_by_pqao -### Title: aqs_qa_one_point_qc_by_pqao -### Aliases: aqs_qa_one_point_qc_by_pqao - -### ** Examples - - # returns a tibble of ozone One Point QC - # data for Jan 2017 - January 2018 where the PQAO is the Massachusetts - # Department of Environmental Protection (agency 0660) - ## Not run: -##D aqs_qa_one_point_qc_by_pqao(parameter = "88101", -##D bdate = as.Date("20170101", -##D format = "%Y%m%d"), -##D edate = as.Date("20180131", -##D format = "%Y%m%d"), -##D pqao_code = "0660" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_one_point_qc_by_pqao", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_one_point_qc_by_site") -### * aqs_qa_one_point_qc_by_site - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_one_point_qc_by_site -### Title: aqs_qa_one_point_qc_by_site -### Aliases: aqs_qa_one_point_qc_by_site - -### ** Examples - -# returns a tibbble of One Point QC data for - # ozone at the Truro National Seashore site (\#0002) in - # Barnstable County, MA for January 2018: - ## Not run: -##D aqs_qa_one_point_qc_by_site(parameter = "44201", -##D bdate = as.Date("20180101", -##D format = "%Y%m%d"), -##D edate = as.Date("20180131", -##D format = "%Y%m%d"), -##D stateFIPS = "25", -##D countycode = "001", -##D sitenum = "0002" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_one_point_qc_by_site", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_one_point_qc_by_state") -### * aqs_qa_one_point_qc_by_state - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_one_point_qc_by_state -### Title: aqs_qa_one_point_qc_by_state -### Aliases: aqs_qa_one_point_qc_by_state - -### ** Examples - -# returns a tibble of one point QC check - # data for ozone in Massachusettes in January 2018 - ## Not run: -##D aqs_qa_one_point_qc_by_state(parameter = "44201", -##D bdate = as.Date("20170101", -##D format = "%Y%m%d" -##D ), -##D edate = as.Date("20190131", -##D format = "%Y%m%d" -##D ), -##D stateFIPS = "25" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_one_point_qc_by_state", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_pep_audit_by_MA") -### * aqs_qa_pep_audit_by_MA - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_pep_audit_by_MA -### Title: aqs_qa_pep_audit_by_MA -### Aliases: aqs_qa_pep_audit_by_MA - -### ** Examples - -# Returns a tibble of PEP audit data for - # June 2017 where the Monitoring Agency is the Alabama Department - # of Environmental Management (agency 0013) - ## Not run: -##D aqs_qa_pep_audit_by_MA(parameter = "88101", -##D bdate = as.Date("20170601", -##D format = "%Y%m%d"), -##D edate = as.Date("20170630", -##D format = "%Y%m%d"), -##D MA_code = "0013" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_pep_audit_by_MA", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_pep_audit_by_county") -### * aqs_qa_pep_audit_by_county - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_pep_audit_by_county -### Title: aqs_qa_pep_audit_by_county -### Aliases: aqs_qa_pep_audit_by_county - -### ** Examples - -# returns a tibble with PEP Audit data for FRM - # PM2.5 in Madison County, AL for 2017 - ## Not run: -##D aqs_qa_pep_audit_by_county_multiyear(parameter = "88101", -##D bdate = as.Date("20150101", -##D format = "%Y%m%d" -##D ), -##D edate = as.Date("20171231", -##D format = "%Y%m%d" -##D ), -##D stateFIPS = "01", -##D countycode = "089" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_pep_audit_by_county", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_pep_audit_by_pqao") -### * aqs_qa_pep_audit_by_pqao - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_pep_audit_by_pqao -### Title: aqs_qa_pep_audit_by_pqao -### Aliases: aqs_qa_pep_audit_by_pqao - -### ** Examples - -# returns a tibble of PEP audit data for - # June 2017 where the pqao is the Alabama Department of - # Environmental Management (agency 0013) - ## Not run: -##D aqs_qa_pep_audit_by_pqao(parameter = "88101", -##D bdate = as.Date("20170601", -##D format = "%Y%m%d" -##D ), -##D edate = as.Date("20190630", -##D format = "%Y%m%d"), -##D pqao_code = "0013" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_pep_audit_by_pqao", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_pep_audit_by_site") -### * aqs_qa_pep_audit_by_site - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_pep_audit_by_site -### Title: aqs_qa_pep_audit_by_site -### Aliases: aqs_qa_pep_audit_by_site - -### ** Examples - -# returns a tibble of pep Audit data for FRM PM2.5 - # at the Huntsville Old Airport site (\#0014) in Madison County, - # AL for 2017 - 2019. - ## Not run: -##D aqs_qa_pep_audit_by_site(parameter = "88101", -##D bdate = as.Date("20170101", -##D format = "%Y%m%d"), -##D edate = as.Date("20191231", -##D format = "%Y%m%d"), -##D stateFIPS = "01", -##D countycode = "089", -##D sitenum = "0014" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_pep_audit_by_site", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_qa_pep_audit_by_state") -### * aqs_qa_pep_audit_by_state - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_qa_pep_audit_by_state -### Title: aqs_qa_pep_audit_by_state -### Aliases: aqs_qa_pep_audit_by_state - -### ** Examples - -# returns a tibble of PEP audit data for PM2.5 in Alabama 2017 - ## Not run: -##D aqs_qa_pep_audit_by_state_multiyear(parameter="88101", -##D bdate=as.Date("20160101", -##D format="%Y%m%d"), -##D edate=as.Date("20171231", -##D format="%Y%m%d"), -##D stateFIPS="01" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_qa_pep_audit_by_state", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_quarterlysummary_by_box") -### * aqs_quarterlysummary_by_box - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_quarterlysummary_by_box -### Title: aqs_quarterlysummary_by_box -### Aliases: aqs_quarterlysummary_by_box - -### ** Examples - -# Returns a tibble containing ozone quarterly summaries - # in the vicinity of central Alabama for each quarter in - # between 2015 - 2017 - ## Not run: -##D aqs_quarterlysummary_by_box(parameter = "44201", -##D bdate = as.Date("20150101", -##D format = "%Y%m%d"), -##D edate = as.Date("20171231", -##D format = "%Y%m%d"), -##D minlat = "33.3", -##D maxlat = "33.6", -##D minlon = "-87.0", -##D maxlon = "-86.7" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_quarterlysummary_by_box", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_quarterlysummary_by_cbsa") -### * aqs_quarterlysummary_by_cbsa - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_quarterlysummary_by_cbsa -### Title: aqs_quarterlysummary_by_cbsa -### Aliases: aqs_quarterlysummary_by_cbsa - -### ** Examples - -# Returns a tibble of $NO_{2}$ quartyerly summary - # data the for Charlotte-Concord-Gastonia, NC cbsa for - # each quarter in 2017. - ## Not run: -##D aqs_quarterlysummary_by_cbsa(parameter = "42602", -##D bdate = as.Date("20170101", -##D format = "%Y%m%d"), -##D edate = as.Date("20171231", -##D format = "%Y%m%d"), -##D cbsa_code = "16740" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_quarterlysummary_by_cbsa", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_quarterlysummary_by_county") -### * aqs_quarterlysummary_by_county - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_quarterlysummary_by_county -### Title: aqs_quarterlysummary_by_county -### Aliases: aqs_quarterlysummary_by_county - -### ** Examples - -# returns a tibble containing quarterly summaries for - # FRM/FEM PM2.5 data for Wake County, NC for each quarter of 2016 - ## Not run: -##D aqs_quarterlysummary_by_county(parameter = "88101", -##D bdate = as.Date("20160101", -##D format = "%Y%m%d"), -##D edate = as.Date("20170228", -##D format = "%Y%m%d"), -##D stateFIPS = "37", -##D countycode = "183" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_quarterlysummary_by_county", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_quarterlysummary_by_site") -### * aqs_quarterlysummary_by_site - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_quarterlysummary_by_site -### Title: aqs_quarterlysummary_by_site -### Aliases: aqs_quarterlysummary_by_site - -### ** Examples - -# returns a tibble containing quarterly summaries for - # FRM/FEM PM2.5 data for Millbrook School in Wake County, NC - # for each quarter of 2016 - ## Not run: -##D aqs_quarterlysummary_by_site(parameter = "88101", -##D bdate = as.Date("20160101", -##D format = "%Y%m%d"), -##D edate = as.Date("20160331", -##D format = "%Y%m%d"), -##D stateFIPS = "37", -##D countycode = "183", -##D sitenum = "0014" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_quarterlysummary_by_site", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_quarterlysummary_by_state") -### * aqs_quarterlysummary_by_state - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_quarterlysummary_by_state -### Title: aqs_quarterlysummary_by_state -### Aliases: aqs_quarterlysummary_by_state - -### ** Examples - -# Returns an aqs S3 object containing quarterly summaries for - # FRM/FEM PM2.5 data for North Carolina for each quater of 2016 - ## Not run: -##D aqs_quarterlysummary_by_state(parameter = "88101", -##D bdate = as.Date("20160101", -##D format = "%Y%m%d"), -##D edate = as.Date("20171231", -##D format = "%Y%m%d"), -##D stateFIPS = "37" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_quarterlysummary_by_state", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_removeheader") -### * aqs_removeheader - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_removeheader -### Title: aqs_removeheader -### Aliases: aqs_removeheader - -### ** Examples - - ## Not run: AQSobject <- aqs_removeheader(AQSobject) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_removeheader", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_revisionhistory") -### * aqs_revisionhistory - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_revisionhistory -### Title: aqs_revisionhistory -### Aliases: aqs_revisionhistory - -### ** Examples - - # Returns a DataFrame of the EPA AQS Data Mart API revision history - # \dontrun{aqs_revisionHistory()} - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_revisionhistory", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_sampledata_by_box") -### * aqs_sampledata_by_box - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_sampledata_by_box -### Title: aqs_sampledata_by_box -### Aliases: aqs_sampledata_by_box - -### ** Examples - -# Returns a tibble containing all ozone samples - # in the vicinity of central Alabama between - # May 1, 2015 - May 2, 2017 - ## Not run: -##D aqs_sampledata_by_box(parameter = "44201", -##D bdate = as.Date("20150501", -##D format = "%Y%m%d"), -##D edate = as.Date("20170502", -##D format = "%Y%m%d"), -##D minlat = "33.3", -##D maxlat = "33.6", -##D minlon = "-87.0", -##D maxlon = "-86.7" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_sampledata_by_box", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_sampledata_by_cbsa") -### * aqs_sampledata_by_cbsa - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_sampledata_by_cbsa -### Title: aqs_sampledata_by_cbsa -### Aliases: aqs_sampledata_by_cbsa - -### ** Examples - -# returns tibble which contains $NO_{2}$ data - # for Charlotte-Concord-Gastonia, NC cbsa for - # Janurary 1, 2015 - Janurary 01, 2017 - ## Not run: -##D aqs_sampledata_by_cbsa(parameter = "42602", -##D bdate = as.Date("20150101", -##D format = "%Y%m%d"), -##D edate = as.Date("20170101", -##D format = "%Y%m%d"), -##D cbsa_code = "16740" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_sampledata_by_cbsa", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_sampledata_by_county") -### * aqs_sampledata_by_county - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_sampledata_by_county -### Title: aqs_sampledata_by_county -### Aliases: aqs_sampledata_by_county - -### ** Examples - -# returns all FRM/FEM PM2.5 data for Wake County, NC between - # January 1, 2015 - February 28, 2016 - ## Not run: -##D aqs_sampledata_by_county(parameter = "88101", -##D bdate = as.Date("20150101", -##D format = "%Y%m%d"), -##D edate=as.Date("20160228", -##D format = "%Y%m%d"), -##D stateFIPS = "37", -##D countycode = "183" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_sampledata_by_county", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_sampledata_by_site") -### * aqs_sampledata_by_site - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_sampledata_by_site -### Title: aqs_sampledata_by_site -### Aliases: aqs_sampledata_by_site - -### ** Examples - -#Returns a table of ozone monitoring data for the Millbrook School - # site (/#0014) in Wake County, NC for June 18, 2017. - ## Not run: -##D aqs_sampledata_by_site(parameter = "44201", -##D bdate = as.Date("20170618", -##D format = "%Y%m%d"), -##D edate = as.Date("20190618", -##D format = "%Y%m%d"), -##D stateFIPS = "37", -##D countycode = "183", -##D sitenum = "0014" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_sampledata_by_site", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_sampledata_by_state") -### * aqs_sampledata_by_state - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_sampledata_by_state -### Title: aqs_sampledata_by_state -### Aliases: aqs_sampledata_by_state - -### ** Examples - -# Returns a tibble with all benzene samples from - # North Carolina collected from May 15th, 1995 - May 15, 1999 - ## Not run: -##D aqs_sampledata_by_state(parameter = "45201", -##D bdate = as.Date("19950515", -##D format="%Y%m%d" -##D ), -##D edate = as.Date("19990515", -##D format = "%Y%m%d"), -##D stateFIPS = "37" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_sampledata_by_state", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_sampledurations") -### * aqs_sampledurations - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_sampledurations -### Title: aqs_sampledurations -### Aliases: aqs_sampledurations - -### ** Examples - -# Returns a tibble or an AQS_Data Mart_APIv2 S3 object of - ## Not run: aqs_sampledurations() - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_sampledurations", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_sign_up") -### * aqs_sign_up - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_sign_up -### Title: aqs_sign_up -### Aliases: aqs_sign_up - -### ** Examples - -# to register a new user or generate a new key with the email - # address "John.Doe/@myemail.com" - ## Not run: aqs_sign_up(email = "John.Doe/@myemail.com") - # after calling this function please follow the instructions that - # are sent in the verification e-mail before proceeding. - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_sign_up", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_sites_by_county") -### * aqs_sites_by_county - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_sites_by_county -### Title: aqs_sites_by_county -### Aliases: aqs_sites_by_county - -### ** Examples - -# Returns an AQS_Data Mart_APIv2 S3 object witch returns all sites - # in Hawaii County, HI - ## Not run: -##D aqs_sites_by_county(stateFIPS = "15", -##D countycode = "001") -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_sites_by_county", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_states") -### * aqs_states - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_states -### Title: aqs_states -### Aliases: aqs_states - -### ** Examples - -# Returns a tibble of states and their FIPS codes - ## Not run: aqs_states() - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_states", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_transactionsample_by_MA") -### * aqs_transactionsample_by_MA - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_transactionsample_by_MA -### Title: aqs_transactionsample_MA -### Aliases: aqs_transactionsample_by_MA - -### ** Examples - -#Returns a tibble of ozone transaction sample data for all monitors - #operated by South Coast Air Quality Management District collected - #on May 15, 2015 - ## Not run: -##D aqs_transactionsample_by_MA(parameter = "44201", -##D bdate = as.Date("20150515", -##D format = "%Y%m%d"), -##D edate = as.Date("20150515", -##D format = "%Y%m%d"), -##D MA_code = "0972" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_transactionsample_by_MA", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_transactionsample_by_county") -### * aqs_transactionsample_by_county - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_transactionsample_by_county -### Title: aqs_transactionsample_by_county -### Aliases: aqs_transactionsample_by_county - -### ** Examples - - ## Not run: -##D # Returns all FRM/FEM transaction data for -##D # Wake County, NC between on Feb 28, 2016. -##D aqs_transactionsample_by_county(parameter = "88101", -##D bdate = as.Date("20160228", -##D format = "%Y%m%d"), -##D edate = as.Date("20160228", -##D format = "%Y%m%d"), -##D stateFIPS = "37", -##D countycode = "183" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_transactionsample_by_county", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_transactionsample_by_site") -### * aqs_transactionsample_by_site - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_transactionsample_by_site -### Title: aqs_transactionsample_by_site -### Aliases: aqs_transactionsample_by_site - -### ** Examples - -#Returns a AQS_Data Mart_APIv2 S3 object of the returns - ## Not run: -##D # returns all ozone transaction data for the -##D # Millbrook School site (#0014) in Wake County, NC for -##D # June 18, 2017 -##D aqs_transactionsample_by_site(parameter = "44201", -##D bdate = as.Date("20170618", -##D format = "%Y%m%d"), -##D edate = as.Date("20170618", -##D format = "%Y%m%d"), -##D stateFIPS = "37", -##D countycode = "183", -##D sitenum = "0014" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_transactionsample_by_site", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -cleanEx() -nameEx("aqs_transactionsample_by_state") -### * aqs_transactionsample_by_state - -flush(stderr()); flush(stdout()) - -base::assign(".ptime", proc.time(), pos = "CheckExEnv") -### Name: aqs_transactionsample_by_state -### Title: aqs_transactionsample_by_state -### Aliases: aqs_transactionsample_by_state - -### ** Examples - -#Returns a AQS_Data Mart_APIv2 S3 object of - ## Not run: -##D # Returns a tibble containing benzene transaction sample -##D # data for North Carolina on May 15, 1995 -##D aqs_transactionsample_by_state(parameter = "45201", -##D bdate = as.Date("19950515", -##D format = "%Y%m%d"), -##D edate = as.Date("19950515", -##D format = "%Y%m%d"), -##D stateFIPS = "37" -##D ) -##D -## End(Not run) - - - -base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv") -base::cat("aqs_transactionsample_by_state", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t") -### *