ropensci / software-review

rOpenSci Software Peer Review.
292 stars 104 forks source link

mbquartR: Finding Manitoba Quarter Sections #658

Open alex-koiter opened 1 month ago

alex-koiter commented 1 month ago

Submitting Author Name: Alexander Koiter Submitting Author Github Handle: !--author1-->@alex-koiter<!--end-author1-- Other Package Authors Github handles: (comma separated, delete if none) Repository: https://github.com/alex-koiter/mbquartR Version submitted: 0.0.0.9000 Submission type: Standard Editor: !--editor-->@jhollist<!--end-editor-- Reviewers: !--reviewers-list-->@sheilasaia<!--end-reviewers-list--

Due date for @sheilasaia: 2024-11-29

Archive: TBD Version accepted: TBD Language: en


Package: mbquartR Title: Finding Manitoba Quarter Sections Version: 0.0.0.9000 Authors@R: person("Alex", "Koiter", , "koitera@brandonu.ca", role = c("aut", "cre"), comment = c(ORCID = "0000-0002-9355-9561")) Description: This package has three main functions: 1) find the coordinates of a quarter sections given the legal land description (e.g., "NE-11-33-29W"); 2) find the legal land description using coordinates (lat and long); and 3) plot these points on a map. License: MIT + file LICENSE URL: http://alexkoiter.ca/mbquartR/, https://github.com/alex-koiter/mbquartR BugReports: https://github.com/alex-koiter/mbquartR/issues Encoding: UTF-8 Roxygen: list(markdown = TRUE) RoxygenNote: 7.3.1 Suggests: testthat (>= 3.0.0), curl (>= 5.2.1), knitr, rmarkdown Config/testthat/edition: 3 Imports: dplyr (>= 1.1.4), purrr (>= 1.0.2), sf (>= 1.0.16), tibble (>= 3.2.1), tidyr (>= 1.3.1), stringr (>= 1.5.1), units (>= 0.8.5), mapview (>= 2.11.2), readr (>= 2.1.4), crayon (>= 1.5.2), rlang VignetteBuilder: knitr

Scope

This package enables users to download the Manitoba Original Survey Legal Descriptions data from the Manitoba government geoportal. It includes functions that allow users to easily search for parcels of land (i.e., quarter sections) by either the legal land description or by coordinates and plot them on an interactive map.

The target audience are those who work with geospatial data in Manitoba, particularly those who are working with rural or farm parcels of land where the legal land description is commonly used as the method of identifying the location. Also anyone who needs to quickly go back and forth between geographic coordinates and the legal land description. Currently, there are a few web-based tools (https://geoportal.gov.mb.ca/datasets/11fa11f9015b45438d6493dcb3d8071c/, https://www.masc.mb.ca/masc.nsf/land_parcel_info.html, https://legallandconverter.com/p4.html) that allow users to locate land parcels but do not allow for batch processing, do not return coordinates, and/or are fee based. Being able to convert back and forth is also helpful for scientist preparing outreach materials.

No

NA. This package provides access to publicly available data.

https://github.com/ropensci/software-review/issues/649

pkgcheck passes fully with github actions but fails locally because it doesn't think I have CI (but I do).

Technical checks

Confirm each of the following by checking the box.

This package:

Publication options

MEE Options - [ ] The package is novel and will be of interest to the broad readership of the journal. - [ ] The manuscript describing the package is no longer than 3000 words. - [ ] You intend to archive the code for the package in a long-term repository which meets the requirements of the journal (see [MEE's Policy on Publishing Code](http://besjournals.onlinelibrary.wiley.com/hub/journal/10.1111/(ISSN)2041-210X/journal-resources/policy-on-publishing-code.html)) - (*Scope: Do consider MEE's [Aims and Scope](http://besjournals.onlinelibrary.wiley.com/hub/journal/10.1111/(ISSN)2041-210X/aims-and-scope/read-full-aims-and-scope.html) for your manuscript. We make no guarantee that your manuscript will be within MEE scope.*) - (*Although not required, we strongly recommend having a full manuscript prepared when you submit here.*) - (*Please do not submit your package separately to Methods in Ecology and Evolution*)

Code of conduct

ropensci-review-bot commented 1 month ago

Thanks for submitting to rOpenSci, our editors and @ropensci-review-bot will reply soon. Type @ropensci-review-bot help for help.

ropensci-review-bot commented 1 month ago

:rocket:

Editor check started

:wave:

ropensci-review-bot commented 1 month ago

Checks for mbquartR (v0.0.0.9000)

git hash: 49820566

Package License: MIT + file LICENSE


1. Package Dependencies

Details of Package Dependency Usage (click to open)

The table below tallies all function calls to all packages ('ncalls'), both internal (r-base + recommended, along with the package itself), and external (imported and suggested packages). 'NA' values indicate packages to which no identified calls to R functions could be found. Note that these results are generated by an automated code-tagging system which may not be entirely accurate. |type |package | ncalls| |:----------|:---------|------:| |internal |base | 15| |internal |mbquartR | 15| |internal |utils | 4| |internal |stats | 2| |imports |dplyr | 9| |imports |sf | 7| |imports |tibble | 2| |imports |readr | 2| |imports |purrr | 1| |imports |mapview | 1| |imports |tidyr | NA| |imports |stringr | NA| |imports |units | NA| |imports |crayon | NA| |imports |rlang | NA| |suggests |testthat | NA| |suggests |curl | NA| |suggests |knitr | NA| |suggests |rmarkdown | NA| |linking_to |NA | NA| Click below for tallies of functions used in each package. Locations of each call within this package may be generated locally by running 's <- pkgstats::pkgstats()', and examining the 'external_calls' table.

base

c (7), getOption (2), by (1), curlGetHeaders (1), force (1), paste0 (1), search (1), url (1)

mbquartR

cache_file (3), cache_dir (2), cache_load (2), centroid (2), cache_check (1), cache_dl (1), closest_centoid (1), map_quarter (1), quarters_dl (1), search_coord (1)

dplyr

mutate (2), select (2), (1), join_by (1), last_col (1), rename (1), right_join (1)

sf

st_as_sf (5), st_transform (2)

utils

data (2), menu (2)

readr

read_csv (2)

stats

dist (2)

tibble

rowid_to_column (1), tibble (1)

mapview

mapview (1)

purrr

map2 (1)

**NOTE:** Some imported packages appear to have no associated function calls; please ensure with author that these 'Imports' are listed appropriately.


2. Statistical Properties

This package features some noteworthy statistical properties which may need to be clarified by a handling editor prior to progressing.

Details of statistical properties (click to open)

The package has: - code in R (100% in 5 files) and - 1 authors - 1 vignette - no internal data file - 11 imported packages - 4 exported functions (median 19 lines of code) - 21 non-exported functions in R (median 7 lines of code) --- Statistical properties of package structure as distributional percentiles in relation to all current CRAN packages The following terminology is used: - `loc` = "Lines of Code" - `fn` = "function" - `exp`/`not_exp` = exported / not exported All parameters are explained as tooltips in the locally-rendered HTML version of this report generated by [the `checks_to_markdown()` function](https://docs.ropensci.org/pkgcheck/reference/checks_to_markdown.html) The final measure (`fn_call_network_size`) is the total number of calls between functions (in R), or more abstract relationships between code objects in other languages. Values are flagged as "noteworthy" when they lie in the upper or lower 5th percentile. |measure | value| percentile|noteworthy | |:------------------------|-----:|----------:|:----------| |files_R | 5| 31.6| | |files_vignettes | 1| 62.0| | |files_tests | 5| 76.5| | |loc_R | 176| 20.2| | |loc_vignettes | 52| 9.3| | |loc_tests | 110| 39.4| | |num_vignettes | 1| 59.0| | |n_fns_r | 25| 34.3| | |n_fns_r_exported | 4| 20.0| | |n_fns_r_not_exported | 21| 41.1| | |n_fns_per_file_r | 3| 45.9| | |num_params_per_fn | 2| 8.2| | |loc_per_fn_r | 9| 24.9| | |loc_per_fn_r_exp | 20| 46.4| | |loc_per_fn_r_not_exp | 7| 18.9| | |rel_whitespace_R | 28| 33.0| | |rel_whitespace_vignettes | 54| 19.0| | |rel_whitespace_tests | 25| 41.2| | |doclines_per_fn_exp | 29| 31.1| | |doclines_per_fn_not_exp | 0| 0.0|TRUE | |fn_call_network_size | 16| 40.7| | ---

2a. Network visualisation

Click to see the interactive network visualisation of calls between objects in package


3. goodpractice and other checks

Details of goodpractice checks (click to open)

#### 3a. Continuous Integration Badges [![R-CMD-check.yaml](https://github.com/alex-koiter/mbquartR/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/alex-koiter/mbquartR/actions) [![pkgcheck](https://github.com/alex-koiter/mbquartR/workflows/pkgcheck/badge.svg)](https://github.com/alex-koiter/mbquartR/actions) **GitHub Workflow Results** | id|name |conclusion |sha | run_number|date | |-----------:|:--------------------------|:----------|:------|----------:|:----------| | 10967106383|pages build and deployment |success |284672 | 9|2024-09-20 | | 10967082710|pkgcheck |success |498205 | 3|2024-09-20 | | 10967082712|pkgdown |success |498205 | 10|2024-09-20 | | 10967082708|R-CMD-check |success |498205 | 17|2024-09-20 | | 10967082707|test-coverage |success |498205 | 17|2024-09-20 | --- #### 3b. `goodpractice` results #### `R CMD check` with [rcmdcheck](https://r-lib.github.io/rcmdcheck/) rcmdcheck found no errors, warnings, or notes #### Test coverage with [covr](https://covr.r-lib.org/) Package coverage: 87.97 #### Cyclocomplexity with [cyclocomp](https://github.com/MangoTheCat/cyclocomp) No functions have cyclocomplexity >= 15 #### Static code analyses with [lintr](https://github.com/jimhester/lintr) [lintr](https://github.com/jimhester/lintr) found the following 1 potential issues: message | number of times --- | --- Avoid library() and require() calls in packages | 1


Package Versions

|package |version | |:--------|:--------| |pkgstats |0.1.6.17 | |pkgcheck |0.1.2.58 |


Editor-in-Chief Instructions:

This package is in top shape and may be passed on to a handling editor

adamhsparks commented 1 month ago

Hi @alex-koiter, the rOpenSci bot says this is all good, but when I run checks locally, I get an error.

> devtools::check()
══ Documenting ════════════════════════════════════════════════════════════════════════════
ℹ Installed roxygen2 version (7.3.2) doesn't match required (7.3.1)
✖ `check()` will not re-document this package
══ Building ═══════════════════════════════════════════════════════════════════════════════
Setting env vars:
• CFLAGS    : -Wall -pedantic -fdiagnostics-color=always
• CXXFLAGS  : -Wall -pedantic -fdiagnostics-color=always
• CXX11FLAGS: -Wall -pedantic -fdiagnostics-color=always
• CXX14FLAGS: -Wall -pedantic -fdiagnostics-color=always
• CXX17FLAGS: -Wall -pedantic -fdiagnostics-color=always
• CXX20FLAGS: -Wall -pedantic -fdiagnostics-color=always
── R CMD build ────────────────────────────────────────────────────────────────────────────
✔  checking for file ‘/Users/adamsparks/tmp/mbquartR/DESCRIPTION’ ...
─  preparing ‘mbquartR’:
✔  checking DESCRIPTION meta-information ...
─  installing the package to build vignettes
E  creating vignettes (1.5s)
   --- re-building ‘mbquartR.Rmd’ using rmarkdown

   Quitting from lines 69-71 [example] (mbquartR.Rmd)
   Error: processing vignette 'mbquartR.Rmd' failed with diagnostics:
   Data doesn't exist, please download with `quarters_dl()` first
   --- failed re-building ‘mbquartR.Rmd’

   SUMMARY: processing the following file failed:
     ‘mbquartR.Rmd’

   Error: Vignette re-building failed.
   Execution halted
Error:
! ! System command 'R' failed
Show Traceback

Please ignore the roxygen2 comment, I'm concerned about the Error creating vignettes.

alex-koiter commented 1 month ago

Thanks @adamhsparks! The issue was that the vignette needed to access data that hadn't been downloaded yet. I have now created some sample data that the vignette uses. Also found some additional typos and made a few other small changes. It should work now.

adamhsparks commented 1 month ago

Looks good, @alex-koiter. Thanks, I'll proceed from here.

adamhsparks commented 1 month ago

@ropensci-review-bot assign @jhollist as editor

ropensci-review-bot commented 1 month ago

Assigned! @jhollist is now the editor

jhollist commented 1 month ago

@alex-koiter I will take some time today/tomorrow to dig into this a bit and will get back to you with any suggestions. Looking forward to the review process!

jhollist commented 1 month ago

@alex-koiter I am just now starting to look at this (apologies!!) I still get the the same error as @adamhsparks with the vignette build. I have cloned and attempted to build https://github.com/alex-koiter/mbquartR and get the error. Perhaps the fix wasn't pushed?

Also I see no documentation on your non-exported functions (Statistical Properties in https://github.com/ropensci/software-review/issues/658#issuecomment-2366968970). While not technically required, it would be an easy area of improvement to add documentation on these non-exported functions.

alex-koiter commented 1 month ago

@jhollist It turns out that I only partially resolved the issue (or fixed a different one). I have resolved the error so you should be able to clone and build the package now. I will take me a few days to get the documentation for the internal functions completed and I will let you know once that is done. Thanks!

jhollist commented 1 month ago

And FYI, check runs now on my machine! I did see this:


─ checking examples ... [43s] OK (43.4s) Examples with CPU (user + system) or elapsed time > 5s user system elapsed map_quarter 23.53 2.08 28.48 search_coord 10.39 0.65 8.47

I know this is system specific so might not be a real issue, but if there is an easy way to have the example run a bit faster that would be good.

alex-koiter commented 3 weeks ago

@jhollist The internal function documentation is now complete. As for the run time, I think this may be an artifact of how the functions are written. This is where the reviewers may be able to provide some suggestions. Thanks!

jhollist commented 2 weeks ago

@alex-koiter Thanks! Looks good on my end. Will start looking for reviewers now.

jhollist commented 3 days ago

@ropensci-review-bot assign @sheilasaia as reviewer

ropensci-review-bot commented 3 days ago

@sheilasaia added to the reviewers list. Review due date is 2024-11-29. Thanks @sheilasaia for accepting to review! Please refer to our reviewer guide.

rOpenSci’s community is our best asset. We aim for reviews to be open, non-adversarial, and focused on improving software quality. Be respectful and kind! See our reviewers guide and code of conduct for more.

ropensci-review-bot commented 3 days ago

@sheilasaia: If you haven't done so, please fill this form for us to update our reviewers records.