Skip to content

Commit

Permalink
Develop (#232)
Browse files Browse the repository at this point in the history
* Bump version number (1.0.0.9000)

[skip ci]

* spelling fixes and removing special Mac install instructions (#229)

* spelling fixes and removing special Mac install instructions

* adding mac back into CI

* Cran preparations (#230)

* Added example for default_version, updated LICENSE year, added R CMD CHECK results

* Comment about Tidy and Mac and HTML validation

* Updated CITATION file

* Updated version numbers

* cleaning up (#231)

* Added example for default_version, updated LICENSE year, added R CMD CHECK results

* Comment about Tidy and Mac and HTML validation

* Updated CITATION file

* Updated version numbers

* Removed auto package version in citation

* Updated CRAN comments

* Fixed typo in CITATION

* Resubmitted

---------

Co-authored-by: Fonti Kar <f.kar@unsw.edu.au>

---------

Co-authored-by: Daniel Falster <daniel.falster@unsw.edu.au>
Co-authored-by: Fonti Kar <f.kar@unsw.edu.au>
  • Loading branch information
3 people authored Jun 16, 2024
1 parent 731e197 commit 8c9ac76
Show file tree
Hide file tree
Showing 16 changed files with 77 additions and 119 deletions.
1 change: 1 addition & 0 deletions .github/workflows/R-CMD-check.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ jobs:
fail-fast: false
matrix:
config:
- {os: macos-latest, r: 'release'}
- {os: windows-latest, r: 'release'}
- {os: ubuntu-latest, r: 'release'}
- {os: ubuntu-latest, r: 'oldrel-1'}
Expand Down
3 changes: 3 additions & 0 deletions CRAN-SUBMISSION
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
Version: 1.0.1
Date: 2024-05-30 01:18:42 UTC
SHA: be4da3ec059e3058eda7799cc9f6396be459d455
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package: APCalign
Title: Resolving Plant Taxon Names Using the Australian Plant Census
Version: 1.0.0
Version: 1.0.1
Authors@R: c(
person(given = "Daniel", family = "Falster", role = c("aut", "cre", "cph"), email = "daniel.falster@unsw.edu.au", comment = c(ORCID = "0000-0002-9814-092X")),
person(given = "Elizabeth", family = "Wenk", role = c("aut", "ctb"), email = "e.wenk@unsw.edu.au", comment = c(ORCID = "0000-0001-5640-5910")),
Expand Down
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
YEAR: 2023
YEAR: 2024
COPYRIGHT HOLDER: Daniel Falster
8 changes: 2 additions & 6 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# APCalign 1.0.0
# APCalign 1.0.1

First major release of APCalign. A preprint is available at
https://www.biorxiv.org/content/10.1101/2024.02.02.578715v1.
Expand All @@ -12,7 +12,7 @@ streamlined the package.
* Write a replacement function for `stringr::word` that is much faster.
* Additional speed up and accuracy of fuzzy_match function by
- Restricting reference list to names with the same first letter as input string.
- Switch from using `utils::adist` to `stringdist:stringdist(method = "dl")`
- Switch from using `utils::adist` to `stringdist::stringdist(method = "dl")`
* Rework `standardise_names` to remove punctuation from the start of the string
* Rework `strip_names_extra` (previously `strip_names_2`) to just perform
additional functions to `strip_names`, rather than repeating those performed by `strip_names`.
Expand All @@ -23,10 +23,6 @@ and removing functions from @import
* Refine tests
* Make messages to console optional
* Fix issue with fails when github is down (https://github.com/traitecoevo/APCalign/issues/205)

# APCalign 0.1.5


* Update installation instructions
* Added how to cite and version APCalign as an article
* Exported `default_version`
Expand Down
2 changes: 1 addition & 1 deletion R/align_taxa.R
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
#' synonyms, orthographic variants) over fuzzy matches.
#' - It prioritises matches to taxa in the APC over names in the APNI.
#' - It identifies string patterns in input names that suggest a name can only
#' be aligned to a genus (hybrids that are not in the APC/ANI; graded species;
#' be aligned to a genus (hybrids that are not in the APC/APNI; graded species;
#' taxa not identified to species), and indicates these names only have a
#' genus-rank match.
#'
Expand Down
2 changes: 1 addition & 1 deletion R/load_taxonomic_resources.R
Original file line number Diff line number Diff line change
Expand Up @@ -372,7 +372,7 @@ dataset_access_function <-
#' version is specified.
#'
#' @return A character string representing the default version for stable data.
#'
#' @example default_version()
#'
#' @export

Expand Down
2 changes: 1 addition & 1 deletion R/update_taxonomy.R
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
#' Notes:
#' - As the input for this function is a table with 5 columns (output by
#' align_taxa), this function will only be used when you explicitly want to
#' separate the aligment and updating components of APCalign. This function is
#' separate the alignment and updating components of APCalign. This function is
#' the second half of create_taxonomic_update_lookup.
#'
#' @family taxonomic alignment functions
Expand Down
32 changes: 10 additions & 22 deletions README.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -25,35 +25,23 @@ library(APCalign)

# APCalign <img src="man/figures/APCalign_hex_2.svg" align="right" width="120"/>

'APCalign' uses the [Australian Plant Census (APC)](https://biodiversity.org.au/nsl/services/search/taxonomy) and [Australian Plant Name Index](https://biodiversity.org.au/nsl/services/search/names) to align and update Australian plant taxon name strings. 'APCalign' also supplies information about
the established status (native/introduced) of plant taxa across different states/territories.
`APCalign` uses the [Australian Plant Census (APC)](https://biodiversity.org.au/nsl/services/search/taxonomy) and [Australian Plant Name Index](https://biodiversity.org.au/nsl/services/search/names) to align and update Australian plant taxon name strings. 'APCalign' also supplies information about
the established status (native/introduced) of plant taxa across different states/territories. It's useful for updating species list and intersecting them with the APC consensus understanding of established status (native/introduced).

## Installation

For Windows and Linux:

```{r install, eval= FALSE}
# install.packages("remotes")
# remotes::install_github("traitecoevo/APCalign", dependencies = TRUE, upgrade = "ask")
```

for MacOS there is currently an extra line needed to install a working binary of the `arrow` dependency from r-universe instead of CRAN:

```{r install_mac, eval= FALSE}
# install.packages("arrow", repos = c('https://apache.r-universe.dev', 'https://cloud.r-project.org'))
# remotes::install_github("traitecoevo/APCalign", dependencies = TRUE, upgrade = "ask")
install.packages("remotes")
remotes::install_github("traitecoevo/APCalign")
```


## A quick demo

Generating a look-up table can be done with just one function:

```{r}
```{r,message=FALSE}
library(APCalign)
Expand All @@ -68,7 +56,7 @@ create_taxonomic_update_lookup(

if you're going to use APCalign more than once, it will save you time to load the taxonomic resources into memory first:

```{r}
```{r,message=FALSE}
tax_resources <- load_taxonomic_resources()
Expand All @@ -83,7 +71,7 @@ create_taxonomic_update_lookup(
)
```

Checking for Australian natives:
Checking for a list of species to see if they are classified as Australian natives:

```{r, message=FALSE}
Expand All @@ -96,12 +84,12 @@ We also developed a shiny application for non-R users to update and align their

## Learn more

Highly recommend looking at our [Getting Started](https://traitecoevo.github.io/APCalign/articles/APCalign.html) vignette to learn about how to use 'APCalign'. You can also learn more about our [taxa matching algorithm](https://traitecoevo.github.io/APCalign/articles/updating-taxon-names.html).
Highly recommend looking at our [Getting Started](https://traitecoevo.github.io/APCalign/articles/APCalign.html) vignette to learn about how to use `APCalign`. You can also learn more about our [taxa matching algorithm](https://traitecoevo.github.io/APCalign/articles/updating-taxon-names.html).


## Found a bug?

Did you come across an unexpected taxon name change? Elusive error you can't debug - [submit an issue](https://github.com/traitecoevo/APCalign/issues) and we will try our best to help
Did you come across an unexpected taxon name change? Elusive error you can't debug - [submit an issue](https://github.com/traitecoevo/APCalign/issues) and we will try our best to help.

## Comments and contributions

Expand Down
101 changes: 42 additions & 59 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,31 +10,23 @@ coverage](https://codecov.io/gh/traitecoevo/APCalign/branch/master/graph/badge.s

# APCalign <img src="man/figures/APCalign_hex_2.svg" align="right" width="120"/>

APCalign uses the [Australian Plant Census
`APCalign` uses the [Australian Plant Census
(APC)](https://biodiversity.org.au/nsl/services/search/taxonomy) and
[Australian Plant Name
Index](https://biodiversity.org.au/nsl/services/search/names) to align
and update Australian plant taxon name strings. ‘APCalign’ also supplies
information about the established status (native/introduced) of plant
taxa across different states/territories.
taxa across different states/territories. It’s useful for updating
species list and intersecting them with the APC consensus understanding
of established status (native/introduced).

## Installation

For Windows and Linux:

``` r

# install.packages("remotes")
# remotes::install_github("traitecoevo/APCalign", dependencies = TRUE, upgrade = "ask")
```

for MacOS there is currently an extra line needed to install a working
binary of the `arrow` dependency from r-universe instead of CRAN:

``` r

# install.packages("arrow", repos = c('https://apache.r-universe.dev', 'https://cloud.r-project.org'))
# remotes::install_github("traitecoevo/APCalign", dependencies = TRUE, upgrade = "ask")
install.packages("remotes")
remotes::install_github("traitecoevo/APCalign")

```

## A quick demo
Expand All @@ -52,58 +44,49 @@ create_taxonomic_update_lookup(
"Commersonia rosea"
)
)
#> Checking alignments of 3 taxa
#> ================================================================================================================================================================
#> # A tibble: 3 × 12
#> original_name aligned_name accepted_name suggested_name genus taxon_rank
#> <chr> <chr> <chr> <chr> <chr> <chr>
#> 1 Banksia integrifol… Banksia int… Banksia inte… Banksia integ… Bank… species
#> 2 Acacia longifolia Acacia long… Acacia longi… Acacia longif… Acac… species
#> 3 Commersonia rosea Commersonia… Androcalva r… Androcalva ro… Andr… species
#> # ℹ 6 more variables: taxonomic_dataset <chr>, taxonomic_status <chr>,
#> # scientific_name <chr>, aligned_reason <chr>, update_reason <chr>,
#> # number_of_collapsed_taxa <dbl>
```

#> Loading resources into memory...
#> ================================================================================================================================================================
#> ...done
#> -> of these 2 names have a perfect match to a scientific name in the APC. Alignments being sought for remaining names.
#> # A tibble: 3 × 12
#> original_name aligned_name accepted_name suggested_name genus taxon_rank
#> <chr> <chr> <chr> <chr> <chr> <chr>
#> 1 Banksia integrifol… Banksia int… Banksia inte… Banksia integ… Bank… species
#> 2 Acacia longifolia Acacia long… Acacia longi… Acacia longif… Acac… species
#> 3 Commersonia rosea Commersonia… Androcalva r… Androcalva ro… Andr… species
#> # ℹ 6 more variables: taxonomic_dataset <chr>, taxonomic_status <chr>,
#> # scientific_name <chr>, aligned_reason <chr>, update_reason <chr>,
#> # number_of_collapsed_taxa <dbl>

if you’re going to use APCalign more than once, it will save you time to
load the taxonomic resources into memory first:

``` r

tax_resources <- load_taxonomic_resources()
#> ================================================================================================================================================================

create_taxonomic_update_lookup(
taxa = c(
"Banksia integrifolia",
"Acacia longifolia",
"Commersonia rosea",
"not a species"
),
resources = tax_resources
)
#> # A tibble: 4 × 12
#> original_name aligned_name accepted_name suggested_name genus taxon_rank
#> <chr> <chr> <chr> <chr> <chr> <chr>
#> 1 Banksia integrifol… Banksia int… Banksia inte… Banksia integ… Bank… species
#> 2 Acacia longifolia Acacia long… Acacia longi… Acacia longif… Acac… species
#> 3 Commersonia rosea Commersonia… Androcalva r… Androcalva ro… Andr… species
#> 4 not a species <NA> <NA> <NA> <NA> <NA>
#> # ℹ 6 more variables: taxonomic_dataset <chr>, taxonomic_status <chr>,
#> # scientific_name <chr>, aligned_reason <chr>, update_reason <chr>,
#> # number_of_collapsed_taxa <dbl>
```

#> Loading resources into memory...
#> ================================================================================================================================================================
#> ...done

create_taxonomic_update_lookup(
taxa = c(
"Banksia integrifolia",
"Acacia longifolia",
"Commersonia rosea",
"not a species"
),
resources = tax_resources
)
#> Checking alignments of 4 taxa
#> -> of these 2 names have a perfect match to a scientific name in the APC. Alignments being sought for remaining names.
#> # A tibble: 4 × 12
#> original_name aligned_name accepted_name suggested_name genus taxon_rank
#> <chr> <chr> <chr> <chr> <chr> <chr>
#> 1 Banksia integrifol… Banksia int… Banksia inte… Banksia integ… Bank… species
#> 2 Acacia longifolia Acacia long… Acacia longi… Acacia longif… Acac… species
#> 3 Commersonia rosea Commersonia… Androcalva r… Androcalva ro… Andr… species
#> 4 not a species <NA> <NA> <NA> <NA> <NA>
#> # ℹ 6 more variables: taxonomic_dataset <chr>, taxonomic_status <chr>,
#> # scientific_name <chr>, aligned_reason <chr>, update_reason <chr>,
#> # number_of_collapsed_taxa <dbl>

Checking for Australian natives:
Checking for a list of species to see if they are classified as
Australian natives:

``` r

Expand All @@ -125,7 +108,7 @@ align their taxonomic names. You can find the application here:

Highly recommend looking at our [Getting
Started](https://traitecoevo.github.io/APCalign/articles/APCalign.html)
vignette to learn about how to use APCalign. You can also learn more
vignette to learn about how to use `APCalign`. You can also learn more
about our [taxa matching
algorithm](https://traitecoevo.github.io/APCalign/articles/updating-taxon-names.html).

Expand All @@ -134,7 +117,7 @@ algorithm](https://traitecoevo.github.io/APCalign/articles/updating-taxon-names.
Did you come across an unexpected taxon name change? Elusive error you
can’t debug - [submit an
issue](https://github.com/traitecoevo/APCalign/issues) and we will try
our best to help
our best to help.

## Comments and contributions

Expand Down
15 changes: 3 additions & 12 deletions cran-comments.md
Original file line number Diff line number Diff line change
@@ -1,18 +1,9 @@
## Resubmission
This is a resubmission. This version we have:

* Added measures to gracefully fail should API/internet resources/network is down.

* Minor update to documentation for one function

## R CMD check results

0 errors | 0 warnings | 0 note


## Rev Deps

* There are no reverse dependencies that needed to be checked


* This is a resubmission
* Removed `packageVersion()` from CITATION file
* 2 notes with HTML validation problems on MacOS 14.5

5 changes: 3 additions & 2 deletions inst/CITATION
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
bibentry(
bibtype = "Unpublished",
bibtype = "Article",
title = "APCalign: an R package workflow and app for aligning and updating flora names to the Australian Plant Census",
journal = "Australian Journal of Botany",
author = c(
person(given = "Elizabeth", family = "Wenk", role = c("aut", "ctb"), email = "e.wenk@unsw.edu.au", comment = c(ORCID = "0000-0001-5640-5910")),
person(given = "Will", family = "Cornwell", role = c("aut", "ctb"), email = "w.cornwell@unsw.edu.au", comment = c(ORCID = "0000-0003-4080-4073")),
Expand All @@ -12,6 +13,6 @@ bibentry(
person(given = "Daniel", family = "Falster", role = c("aut", "cre", "cph"), email = "daniel.falster@unsw.edu.au", comment = c(ORCID = "0000-0002-9814-092X"))
),
year = 2024,
note = paste("R package version:", packageVersion("APCalign")),
note = "R package version: 1.0.1",
url = "https://www.biorxiv.org/content/10.1101/2024.02.02.578715v1"
)
2 changes: 1 addition & 1 deletion man/align_taxa.Rd

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

2 changes: 1 addition & 1 deletion man/update_taxonomy.Rd

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

Loading

0 comments on commit 8c9ac76

Please sign in to comment.