Skip to content

Commit

Permalink
prepare for CRAN submission (#155)
Browse files Browse the repository at this point in the history
  • Loading branch information
MattCowgill authored May 24, 2021
1 parent 93ab065 commit d242f35
Show file tree
Hide file tree
Showing 6 changed files with 22 additions and 12 deletions.
5 changes: 2 additions & 3 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Package: readabs
Type: Package
Title: Download and Tidy Time Series Data from the Australian Bureau of Statistics
Version: 0.4.8.903
Version: 0.4.9
Authors@R: c(
person("Matt", "Cowgill", role = c("aut", "cre"), email = "[email protected]", comment = c(ORCID = "0000-0003-0422-3300")),
person("Zoe", "Meers", role = "aut", email = "[email protected]"),
Expand All @@ -11,10 +11,9 @@ Authors@R: c(
Maintainer: Matt Cowgill <[email protected]>
Description: Downloads, imports, and tidies time series data from the
Australian Bureau of Statistics <https://www.abs.gov.au/>.
Date: 2021-02-07
Date: 2021-05-24
License: MIT + file LICENSE
Encoding: UTF-8
LazyData: true
Depends: R (>= 3.5)
Imports:
readxl (>= 1.2.0),
Expand Down
6 changes: 2 additions & 4 deletions NEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,10 @@
# readabs 0.4.8.902
* `check_latest_date()` function to check latest observation date for ABS time series

# readabs 0.4.8.901
* Residual upstream dependence on curl eliminated

# readabs 0.4.8.900
# readabs 0.4.9
* `read_lfs_grossflows()` convenience function added
* `utils::download.file()` used rather than `curl::curl_download()`
* Residual upstream dependence on curl eliminated
* Workaround implemented for changes to ABS Weekly Payrolls release
* `search_catalogues()` function added to make data cubes easier to find

Expand Down
2 changes: 1 addition & 1 deletion R/search_files.R
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
#' list of files within the catalogue.
#' @export
#' @examples
#' search_files("GM1", "labour-force-australia")
#' \dontrun{ search_files("GM1", "labour-force-australia") }

search_files <- function(string, catalogue, refresh = FALSE) {
files <- show_available_files(catalogue_string = catalogue,
Expand Down
2 changes: 1 addition & 1 deletion man/search_files.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file added vignettes/cats.rds
Binary file not shown.
19 changes: 16 additions & 3 deletions vignettes/readabs_vignette.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,10 @@ output:
author: "Matt Cowgill"
vignette: >
%\VignetteIndexEntry{Using readabs}
%\VignetteEngine{knitr::rmarkdown}
%\VignetteEncoding{UTF-8}
%\VignetteEngine{knitr::rmarkdown}
editor_options:
chunk_output_type: console
---

```{r setup, echo = FALSE, message = FALSE}
Expand Down Expand Up @@ -294,17 +296,28 @@ Let's say I want to download cube GM1, the gross flows spreadsheet from the mont

Let's look for the name of the catalogue:

```{r}
```{r, eval = FALSE}
search_catalogues("labour force")
```
```{r, eval = FALSE, include = FALSE}
cats <- search_catalogues("labour force")
saveRDS(cats, "cats.rds")
```
```{r, echo = FALSE}
readRDS("cats.rds")
```

It looks like `labour-force-australia` is the catalogue name for the monthly Labour Force survey.

Now I need to find the filename for the gross flows spreadsheet, GM1.

```{r}
```{r, eval = FALSE}
search_files("GM1", "labour-force-australia")
```
```{r, echo = FALSE}
x <- "GM1.xlsx"
x
```

The GM1 table is, conveniently enough, called `GM1.xlsx`.

Expand Down

0 comments on commit d242f35

Please sign in to comment.