ropensci / software-review

rOpenSci Software Peer Review.
292 stars 104 forks source link

quadkeyr: Tools for converting QuadKeys (Microsoft's Bing Maps Tile System) into raster images #619

Closed flor14 closed 8 months ago

flor14 commented 11 months ago

Date accepted: 2024-03-14

Submitting Author Name: Florencia D'Andrea Submitting Author Github Handle: !--author1-->@flor14<!--end-author1-- Repository: https://github.com/Fernandez-Lab-WSU/quadkeyr Version submitted: Submission type: Standard Editor: !--editor-->@emilyriederer<!--end-editor-- Reviewers: @mpaulacaldas, @vincentvanhees

Archive: TBD Version accepted: TBD Language: en


Package: quadkeyr
Title: Tools for converting QuadKeys used in Microsoft's Bing Maps Tile System into raster images
Version: 0.0.0.9000
Authors@R: 
    person(given = "Florencia",
           family = "D'Andrea", 
           email = "florencia.dandrea@gmail.com", 
           role = c("aut", "cre"),
           comment = c(ORCID = "0000-0002-0041-097X"))
Description: quadkeyr enables the generation of raster images based on QuadKeys, facilitating efficient integration of Bing Maps data into R workflows. In particular, quadkeyr provides support to process and analyze Facebook mobility datasets within the R environment.
License: MIT + file LICENSE
URL: https://fernandez-lab-wsu.github.io/quadkeyr/, https://github.com/Fernandez-Lab-WSU/quadkeyr
BugReports: https://github.com/Fernandez-Lab-WSU/quadkeyr/issues
Encoding: UTF-8
Roxygen: list(markdown = TRUE)
RoxygenNote: 7.2.1
Suggests: 
    knitr,
    rmarkdown,
    shinytest2,
    testthat (>= 3.1.10)
VignetteBuilder: knitr
Depends: 
    R (>= 2.10)
LazyData: true
Imports: 
    bslib (>= 0.5.1),
    dplyr (>= 1.1.2),
    DT (>= 0.27),
    ggplot2 (>= 3.4.3),
    leaflet (>= 2.2.0),
    lubridate (>= 1.9.2),
    purrr (>= 1.0.1),
    readr (>= 2.1.4),
    rnaturalearth (>= 0.3.2),
    sf (>= 1.0.14),
    shiny (>= 1.7.4),
    stars (>= 0.6.2),
    tidyr (>= 1.3.0),
    viridis (>= 0.6.4)

Scope

🗺️ The package offers tools to analyze data reported by QuadKey and convert it to raster images. QuadKeys are strings that encode information about map coordinates and the level of detail of the Bing Maps Tile System.

Anyone trying to analyze data reported in this format. Facebook mobility data, for example, can be reported by QuadKey. This package could help this StackOverflow user or this other one.

The closer R package dealing with this type of data is slippymath which has a more general objective. quadkeyr is only based on Microsoft Bing Maps Tile System documentation and it is focused on raster creation. You can read a list of packages with similar functions in the README references section.

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

Thank you!

ropensci-review-bot commented 11 months 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 11 months ago

:rocket:

Editor check started

:wave:

ropensci-review-bot commented 11 months ago

Checks for quadkeyr (v0.0.0.9000)

git hash: 8f9fc6c2

Important: All failing checks above must be addressed prior to proceeding

(Checks marked with :eyes: may be optionally addressed.)

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 | 154| |internal |quadkeyr | 59| |internal |utils | 40| |internal |graphics | 5| |internal |stats | 1| |imports |sf | 10| |imports |bslib | 8| |imports |dplyr | 8| |imports |stars | 3| |imports |leaflet | 2| |imports |shiny | 2| |imports |purrr | 1| |imports |DT | NA| |imports |ggplot2 | NA| |imports |lubridate | NA| |imports |readr | NA| |imports |rnaturalearth | NA| |imports |tidyr | NA| |imports |viridis | NA| |suggests |knitr | NA| |suggests |rmarkdown | NA| |suggests |shinytest2 | NA| |suggests |testthat | 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

list (22), return (20), c (16), for (11), data.frame (10), nrow (5), seq_len (5), min (4), as.character (3), max (3), nchar (3), pi (3), seq (3), sign (3), abs (2), as.integer (2), as.numeric (2), by (2), file (2), floor (2), options (2), rbind (2), sum (2), unique (2), version (2), as.Date (1), atan (1), character (1), class (1), colnames (1), exp (1), is.na (1), length (1), list.files (1), log (1), ncol (1), paste (1), paste0 (1), rep (1), rev (1), rownames (1), seq_along (1), sin (1), strsplit (1), subset (1), t (1)

quadkeyr

mapsize (9), clip (7), pixelXY_to_latlong (4), quadkey_to_tileXY (4), create_qk_grid (3), missing_combinations (3), pixelXY_to_tileXY (3), tileXY_to_pixelXY (3), complete_grid_for_polygons (2), create_raster (2), extract_qk_coord (2), latlong_to_pixelXY (2), quadkey_to_latlong (2), apply_weekly_lag (1), extract_tile_coord (1), format_data (1), grid_to_polygon (1), ground_res (1), latlong_to_quadkey (1), mapscale (1), polygon_to_raster (1), qkmap_app (1), read_all_files (1), regular_qk_grid (1), server (1), tileXY_to_quadkey (1)

utils

data (40)

sf

st_as_sf (6), st_bbox (2), st_sf (2)

bslib

bs_theme (2), font_google (2), sidebar (2), layout_sidebar (1), page_navbar (1)

dplyr

mutate (5), anti_join (2), lag (1)

graphics

grid (4), title (1)

stars

st_as_stars (1), st_rasterize (1), write_stars (1)

leaflet

addMarkers (1), setView (1)

shiny

eventReactive (2)

purrr

map_dfr (1)

stats

var (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 13 files) and - 1 authors - 3 vignettes - 2 internal data files - 14 imported packages - 24 exported functions (median 13 lines of code) - 27 non-exported functions in R (median 29 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 | 13| 68.2| | |files_vignettes | 3| 92.4| | |files_tests | 13| 93.3| | |loc_R | 556| 50.8| | |loc_vignettes | 349| 68.4| | |loc_tests | 419| 71.4| | |num_vignettes | 3| 94.2| | |data_size_total | 2037768| 97.7|TRUE | |data_size_median | 1018884| 98.5|TRUE | |n_fns_r | 51| 57.3| | |n_fns_r_exported | 24| 72.5| | |n_fns_r_not_exported | 27| 49.7| | |n_fns_per_file_r | 2| 39.8| | |num_params_per_fn | 2| 11.9| | |loc_per_fn_r | 19| 57.3| | |loc_per_fn_r_exp | 13| 30.5| | |loc_per_fn_r_not_exp | 29| 77.1| | |rel_whitespace_R | 48| 77.5| | |rel_whitespace_vignettes | 45| 78.5| | |rel_whitespace_tests | 28| 75.7| | |doclines_per_fn_exp | 21| 15.7| | |doclines_per_fn_not_exp | 0| 0.0|TRUE | |fn_call_network_size | 52| 67.1| | ---

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 [![test-coverage.yaml](https://github.com/Fernandez-Lab-WSU/quadkeyr/actions/workflows/test-coverage.yaml/badge.svg)](https://github.com/Fernandez-Lab-WSU/quadkeyr/actions) [![check-standard.yaml](https://github.com/Fernandez-Lab-WSU/quadkeyr/actions/workflows/check-standard.yaml/badge.svg)](https://github.com/Fernandez-Lab-WSU/quadkeyr/actions) **GitHub Workflow Results** | id|name |conclusion |sha | run_number|date | |----------:|:--------------------------|:----------|:------|----------:|:----------| | 7105875366|pages build and deployment |success |22b70a | 11|2023-12-05 | | 7105846578|pkgdown |success |65762e | 10|2023-12-05 | | 7105846580|R-CMD-check |success |65762e | 10|2023-12-05 | | 7105846581|test-coverage |success |65762e | 10|2023-12-05 | --- #### 3b. `goodpractice` results #### `R CMD check` with [rcmdcheck](https://r-lib.github.io/rcmdcheck/) R CMD check generated the following error: 1. Error in proc$get_built_file() : Build process failed #### Test coverage with [covr](https://covr.r-lib.org/) Package coverage: 61.94 The following files are not completely covered by tests: file | coverage --- | --- R/polygon_to_raster.R | 0% R/qkmap_visualizer.R | 0% R/read_and_format_files.R | 62.16% #### Cyclocomplexity with [cyclocomp](https://github.com/MangoTheCat/cyclocomp) Error : Build failed, unknown error, standard output: * checking for file ‘quadkeyr/DESCRIPTION’ ... OK * preparing ‘quadkeyr’: * checking DESCRIPTION meta-information ... OK * installing the package to build vignettes * creating vignettes ... ERROR --- re-building ‘create_rasters_from_grid.Rmd’ using rmarkdown --- finished re-building ‘create_rasters_from_grid.Rmd’ --- re-building ‘get_grid_from_quadkeys.Rmd’ using rmarkdown File figure/unnamed-chunk-2-1.png not found in resource path Error: processing vignette 'get_grid_from_quadkeys.Rmd' failed with diagnostics: pandoc document conversion failed with error 99 --- failed re-building ‘get_grid_from_quadkeys.Rmd’ --- re-building ‘quadkey_conversion.Rmd’ using rmarkdown --- finished re-building ‘quadkey_conversion.Rmd’ SUMMARY: processing the following file failed: ‘get_grid_from_quadkeys.Rmd’ Error: Vignette re-building failed. Execution halted #### Static code analyses with [lintr](https://github.com/jimhester/lintr) [lintr](https://github.com/jimhester/lintr) found the following 57 potential issues: message | number of times --- | --- Avoid library() and require() calls in packages | 8 Lines should not be more than 80 characters. | 28 Use <-, not =, for assignment. | 21


4. Other Checks

Details of other checks (click to open)

:heavy_multiplication_x: The following 3 function names are duplicated in other packages: - - `clip` from CUFF, ramify - - `create_raster` from SpatialKDE - - `format_data` from GCalcium, popbayes


Package Versions

|package |version | |:--------|:--------| |pkgstats |0.1.3.9 | |pkgcheck |0.1.2.11 |


Editor-in-Chief Instructions:

Processing may not proceed until the items marked with :heavy_multiplication_x: have been resolved.

jhollist commented 11 months ago

@flor14 Thank you for the submission and apologies for the few days that went by prior to my response. Had a high priority thing at work that I had to focus on!

I will take a closer look at your submission early next week. One thing we will need to get figured out is the R CMD Check failures that our build system is seeing. I noticed that the builds on your repo seem to be passing just fine. Stay tuned and thanks again for the submission.

flor14 commented 11 months ago

Thank you @jhollist, don't worry. I have increased the code coverage to 84% adding tests for the Shiny app, so that is solved. About the checks, I am unsure what could be the issue, as all the tests are passing for me as you can see in the repo, but I will try to figure it out.

flor14 commented 11 months ago

@jhollist the RMD checks are failing because there was missing this image, which now is included in the repo: https://github.com/Fernandez-Lab-WSU/quadkeyr/blob/main/figure/unnamed-chunk-2-1.png This is the error that the bot reported:

    creating vignettes ... ERROR
    --- re-building ‘create_rasters_from_grid.Rmd’ using rmarkdown
    --- finished re-building ‘create_rasters_from_grid.Rmd’

--- re-building ‘get_grid_from_quadkeys.Rmd’ using rmarkdown
File figure/unnamed-chunk-2-1.png not found in resource path

I hope that if you run the RMD Checks again, they should be ✅ without issues. Also, I will continue using the package these days and probably improve things, let me know if you want me to do a first release for the review.

jhollist commented 11 months ago

@ropensci-review-bot check package

ropensci-review-bot commented 11 months ago

Thanks, about to send the query.

ropensci-review-bot commented 11 months ago

:rocket:

Editor check started

:wave:

ropensci-review-bot commented 11 months ago

Checks for quadkeyr (v0.0.0.9000)

git hash: 0425b02e

Important: All failing checks above must be addressed prior to proceeding

(Checks marked with :eyes: may be optionally addressed.)

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| |:----------|:-------------|------:| |imports |bslib | NA| |imports |dplyr | NA| |imports |DT | NA| |imports |ggplot2 | NA| |imports |leaflet | NA| |imports |lubridate | NA| |imports |purrr | NA| |imports |readr | NA| |imports |rnaturalearth | NA| |imports |sf | NA| |imports |shiny | NA| |imports |stars | NA| |imports |tidyr | NA| |imports |viridis | NA| |suggests |knitr | NA| |suggests |rmarkdown | NA| |suggests |shinytest2 | NA| |suggests |testthat | 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. **NOTE:** No imported packages appear to have 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 13 files) and - 1 authors - 3 vignettes - 2 internal data files - 14 imported packages - 25 exported functions (median 12 lines of code) - no non-exported function in R (median 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 | 13| 68.2| | |files_vignettes | 3| 92.4| | |files_tests | 14| 93.8| | |loc_R | 439| 43.4| | |loc_vignettes | 450| 75.5| | |loc_tests | 424| 71.6| | |num_vignettes | 3| 94.2| | |data_size_total | 2037768| 97.7|TRUE | |data_size_median | 1018884| 98.5|TRUE | |n_fns_r | 25| 34.7| | |n_fns_r_exported | 25| 73.6| | |n_fns_r_not_exported | 0| 0.0|TRUE | |n_fns_per_file_r | 2| 38.7| | |num_params_per_fn | 2| 11.9| | |loc_per_fn_r | 12| 36.1| | |loc_per_fn_r_exp | 12| 27.7| | |rel_whitespace_R | 52| 74.2| | |rel_whitespace_vignettes | 37| 80.0| | |rel_whitespace_tests | 29| 76.2| | |doclines_per_fn_exp | 21| 15.7| | |fn_call_network_size | 0| 0.0|TRUE | ---

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 [![test-coverage.yaml](https://github.com/Fernandez-Lab-WSU/quadkeyr/actions/workflows/test-coverage.yaml/badge.svg)](https://github.com/Fernandez-Lab-WSU/quadkeyr/actions) [![check-standard.yaml](https://github.com/Fernandez-Lab-WSU/quadkeyr/actions/workflows/check-standard.yaml/badge.svg)](https://github.com/Fernandez-Lab-WSU/quadkeyr/actions) **GitHub Workflow Results** | id|name |conclusion |sha | run_number|date | |----------:|:--------------------------|:----------|:------|----------:|:----------| | 7161851741|pages build and deployment |success |7fb7aa | 20|2023-12-11 | | 7161834160|pkgdown |success |0425b0 | 19|2023-12-11 | | 7161834165|R-CMD-check |success |0425b0 | 19|2023-12-11 | | 7161834161|test-coverage |success |0425b0 | 19|2023-12-11 | --- #### 3b. `goodpractice` results #### `R CMD check` with [rcmdcheck](https://r-lib.github.io/rcmdcheck/) R CMD check generated the following notes: 1. checking installed package size ... NOTE installed size is 6.0Mb sub-directories of 1Mb or more: app 1.5Mb data 2.3Mb doc 1.8Mb 2. checking dependencies in R code ... NOTE Namespaces in Imports field not imported from: ‘bslib’ ‘DT’ ‘ggplot2’ ‘leaflet’ ‘rnaturalearth’ ‘tidyr’ ‘viridis’ All declared Imports should be used. 3. checking R code for possible problems ... NOTE apply_weekly_lag: no visible binding for global variable ‘.data’ create_qk_grid: no visible binding for global variable ‘.data’ grid_to_polygon: no visible binding for global variable ‘.data’ missing_combinations: no visible binding for global variable ‘.data’ polygon_to_raster: no visible binding for global variable ‘.data’ Undefined global functions or variables: .data R CMD check generated the following check_fails: 1. rcmdcheck_imports_not_imported_from 2. rcmdcheck_undefined_globals 3. rcmdcheck_reasonable_installed_size #### Test coverage with [covr](https://covr.r-lib.org/) Package coverage: 83.77 #### Cyclocomplexity with [cyclocomp](https://github.com/MangoTheCat/cyclocomp) The following function have cyclocomplexity >= 15: function | cyclocomplexity --- | --- create_qk_grid | 18 #### Static code analyses with [lintr](https://github.com/jimhester/lintr) [lintr](https://github.com/jimhester/lintr) found the following 73 potential issues: message | number of times --- | --- Avoid library() and require() calls in packages | 15 Lines should not be more than 80 characters. | 29 Use <-, not =, for assignment. | 29


4. Other Checks

Details of other checks (click to open)

:heavy_multiplication_x: The following 3 function names are duplicated in other packages: - - `clip` from CUFF, ramify - - `create_raster` from SpatialKDE - - `format_data` from GCalcium, popbayes


Package Versions

|package |version | |:--------|:--------| |pkgstats |0.1.3.9 | |pkgcheck |0.1.2.11 |


Editor-in-Chief Instructions:

Processing may not proceed until the items marked with :heavy_multiplication_x: have been resolved.

jhollist commented 11 months ago

@flor14 Thanks for tracking down that issue! That was really helpful.

Couple of thoughts for you.

1.) I re-ran the checks and the only thing that comes up now is related to the new function you added, qkmap_app. I am guessing you are still in progress on that. 2.) If you are going to be working on the package in the next few days I would prefer to see you reach a somewhat stable release that we can use as the basis for the review. 3.) If you want to run the checks on your own, you can use the action at https://github.com/ropensci-review-tools/pkgcheck-action.

In the meantime I will look closer at the package and vignettes.

flor14 commented 11 months ago

Thank you @jhollist

1) qkmap_app is a simple function that calls the app from inst/ and it has examples, so I will try to see what that error means in the following days. 2) I won't be working on the package, but I will be heavily using it. And I would probably like to make changes. Let's do this: after I fix the problem with qkmap_app I will not push more changes. 3) Will do it and let you know when everything is working again.

Thank you

jhollist commented 11 months ago

@flor14 Sounds good. Just ping me again here once everything is working again. I have taken a closer look and I think quadkeyr is ready to be passed on to a handling editor. I will do that as soon as you get the changes pushed.

Cheers, Jeff

flor14 commented 11 months ago

@jhollist pkgcheck is passing now, I have added the GitHub action to the repository.

jhollist commented 11 months ago

@ropensci-review-bot check package

ropensci-review-bot commented 11 months ago

Thanks, about to send the query.

ropensci-review-bot commented 11 months ago

:rocket:

Editor check started

:wave:

ropensci-review-bot commented 11 months ago

Checks for quadkeyr (v0.0.0.9000)

git hash: 10376c70

(Checks marked with :eyes: may be optionally addressed.)

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 | 133| |internal |quadkeyr | 48| |internal |utils | 35| |internal |graphics | 3| |internal |stats | 1| |imports |sf | 10| |imports |dplyr | 9| |imports |stars | 3| |imports |purrr | 1| |imports |bslib | NA| |imports |DT | NA| |imports |ggplot2 | NA| |imports |leaflet | NA| |imports |lubridate | NA| |imports |readr | NA| |imports |rnaturalearth | NA| |imports |shiny | NA| |imports |tidyr | NA| |imports |viridis | NA| |suggests |knitr | NA| |suggests |rmarkdown | NA| |suggests |shinytest2 | NA| |suggests |testthat | 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

list (18), return (18), c (16), for (11), data.frame (9), nrow (5), seq_len (5), min (3), nchar (3), pi (3), seq (3), sign (3), abs (2), as.integer (2), by (2), file (2), floor (2), max (2), rbind (2), sum (2), unique (2), as.character (1), as.Date (1), as.numeric (1), atan (1), character (1), colnames (1), exp (1), is.na (1), length (1), list.files (1), log (1), paste0 (1), rev (1), seq_along (1), sin (1), strsplit (1), subset (1), system.file (1)

quadkeyr

clip (7), mapsize (6), missing_combinations (3), pixelXY_to_latlong (3), pixelXY_to_tileXY (3), quadkey_to_tileXY (3), complete_grid_for_polygons (2), create_qk_grid (2), create_raster (2), latlong_to_pixelXY (2), quadkey_to_latlong (2), tileXY_to_pixelXY (2), apply_weekly_lag (1), extract_qk_coord (1), extract_tile_coord (1), format_data (1), grid_to_polygon (1), ground_res (1), latlong_to_quadkey (1), mapscale (1), polygon_to_raster (1), qkmap_app (1), tileXY_to_quadkey (1)

utils

data (35)

sf

st_as_sf (6), st_bbox (2), st_sf (2)

dplyr

mutate (5), anti_join (2), all_of (1), lag (1)

graphics

grid (3)

stars

st_as_stars (1), st_rasterize (1), write_stars (1)

purrr

map_dfr (1)

stats

var (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 13 files) and - 1 authors - 3 vignettes - 2 internal data files - 14 imported packages - 25 exported functions (median 12 lines of code) - 25 non-exported functions in R (median 26 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 | 13| 68.2| | |files_vignettes | 3| 92.4| | |files_tests | 14| 93.8| | |loc_R | 448| 44.1| | |loc_vignettes | 450| 75.5| | |loc_tests | 424| 71.6| | |num_vignettes | 3| 94.2| | |data_size_total | 2037768| 97.7|TRUE | |data_size_median | 1018884| 98.5|TRUE | |n_fns_r | 50| 56.6| | |n_fns_r_exported | 25| 73.6| | |n_fns_r_not_exported | 25| 47.3| | |n_fns_per_file_r | 2| 38.7| | |num_params_per_fn | 2| 11.9| | |loc_per_fn_r | 18| 54.1| | |loc_per_fn_r_exp | 12| 27.7| | |loc_per_fn_r_not_exp | 26| 73.5| | |rel_whitespace_R | 51| 74.2| | |rel_whitespace_vignettes | 37| 80.0| | |rel_whitespace_tests | 29| 76.2| | |doclines_per_fn_exp | 21| 15.7| | |doclines_per_fn_not_exp | 0| 0.0|TRUE | |fn_call_network_size | 46| 64.6| | ---

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 [![pkgcheck.yaml](https://github.com/Fernandez-Lab-WSU/quadkeyr/actions/workflows/pkgcheck.yaml/badge.svg)](https://github.com/Fernandez-Lab-WSU/quadkeyr/actions) [![check-standard.yaml](https://github.com/Fernandez-Lab-WSU/quadkeyr/actions/workflows/check-standard.yaml/badge.svg)](https://github.com/Fernandez-Lab-WSU/quadkeyr/actions) **GitHub Workflow Results** | id|name |conclusion |sha | run_number|date | |----------:|:--------------------------|:----------|:------|----------:|:----------| | 7183862151|pages build and deployment |success |a8f312 | 25|2023-12-12 | | 7183832573|pkgcheck |success |10376c | 4|2023-12-12 | | 7183832572|pkgdown |success |10376c | 24|2023-12-12 | | 7183832584|R-CMD-check |success |10376c | 24|2023-12-12 | | 7183832577|test-coverage |success |10376c | 24|2023-12-12 | --- #### 3b. `goodpractice` results #### `R CMD check` with [rcmdcheck](https://r-lib.github.io/rcmdcheck/) R CMD check generated the following notes: 1. checking installed package size ... NOTE installed size is 6.0Mb sub-directories of 1Mb or more: app 1.5Mb data 2.3Mb doc 1.8Mb 2. checking dependencies in R code ... NOTE Namespaces in Imports field not imported from: ‘bslib’ ‘DT’ ‘ggplot2’ ‘leaflet’ ‘rnaturalearth’ ‘tidyr’ ‘viridis’ All declared Imports should be used. 3. checking R code for possible problems ... NOTE apply_weekly_lag: no visible binding for global variable ‘.data’ create_qk_grid: no visible binding for global variable ‘.data’ grid_to_polygon: no visible binding for global variable ‘.data’ missing_combinations: no visible binding for global variable ‘.data’ polygon_to_raster: no visible binding for global variable ‘.data’ Undefined global functions or variables: .data R CMD check generated the following check_fails: 1. rcmdcheck_imports_not_imported_from 2. rcmdcheck_undefined_globals 3. rcmdcheck_reasonable_installed_size #### Test coverage with [covr](https://covr.r-lib.org/) Package coverage: 83.9 #### Cyclocomplexity with [cyclocomp](https://github.com/MangoTheCat/cyclocomp) The following function have cyclocomplexity >= 15: function | cyclocomplexity --- | --- create_qk_grid | 18 #### Static code analyses with [lintr](https://github.com/jimhester/lintr) [lintr](https://github.com/jimhester/lintr) found the following 48 potential issues: message | number of times --- | --- Avoid library() and require() calls in packages | 15 Lines should not be more than 80 characters. | 12 Use <-, not =, for assignment. | 21


4. Other Checks

Details of other checks (click to open)

:heavy_multiplication_x: The following 3 function names are duplicated in other packages: - - `clip` from CUFF, ramify - - `create_raster` from SpatialKDE - - `format_data` from GCalcium, popbayes


Package Versions

|package |version | |:--------|:--------| |pkgstats |0.1.3.9 | |pkgcheck |0.1.2.11 |


Editor-in-Chief Instructions:

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

jhollist commented 11 months ago

@flor14, looks like we are all set. Are you ready to have me pass this on the a handling editor or do you anticipate a few more changes?

flor14 commented 11 months ago

Yes, I think it is ready. The issue was that my changes were passing the R CMD checks, so I didn't anticipate problems before the review started. Now I learned that pkgcheck works differently and seems to be more strict. If there is any new change (even if it is small) I will retain it to make all of them together after the review, to avoid any potential issue. Thank you @jhollist

jhollist commented 11 months ago

Fantastic! I'll work on getting the handling editor lined up.

On Wed, Dec 13, 2023 at 2:19 PM flor14 @.***> wrote:

Yes, I think it is ready. The issue was that my changes were passing the R CMD checks, so I didn't anticipate issues before the review started. Now I learned that pkgcheck works differently and seems to be more strict. If there is any new change (even if it is small) I will retain it to make all of them together after the review, to avoid any potential issue. Thank you @jhollist https://github.com/jhollist

— Reply to this email directly, view it on GitHub https://github.com/ropensci/software-review/issues/619#issuecomment-1854567174, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABJPYS6I3TOFR5DRWYRWAG3YJH5ULAVCNFSM6AAAAABAIGPWTSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQNJUGU3DOMJXGQ . You are receiving this because you were mentioned.Message ID: @.***>

-- Jeffrey W. Hollister email: @.*** cell: 401 556 4087 https://jwhollister.com

jhollist commented 11 months ago

@flor14 I have found a handling editor (thanks @emilyriederer!). There may be a delay of a week or two before she is able to get started in earnest on this because of a hectic end of year schedule.

jhollist commented 11 months ago

@ropensci-review-bot assign @emilyriederer as editor

ropensci-review-bot commented 11 months ago

Assigned! @emilyriederer is now the editor

flor14 commented 11 months ago

Thank you @jhollist and happy holidays

jhollist commented 11 months ago

Happy holidays to you as well!

emilyriederer commented 11 months ago

Hi @flor14 ! It's great to meet you. Thanks for your submission.

As @jhollist mentioned, I may not be able to engage more fully until next week, but I thought I'd send over a few preliminary observations.

I think this is a compelling project and is close to being ready for reviewers. On a cursory review of the automated outputs, I just had a few small requests to touch up before we hand this off:

Thank you!

flor14 commented 10 months ago

Hello, @emilyriederer, nice to meet you as well.

Including more high-level documentation is a good idea, I have been paying attention mostly to the function documentation so far. Also, I realized that 2 notes were pending in the RMD check, but I had some issues when removing the vignette's dependencies so I kept them. The same with the library() calls that are probably referring to the vignettes. I will try to go more in-depth to fully solve that. I will write a message in this thread to let you know when is done. Thank you!

emilyriederer commented 10 months ago

Hi @flor14 ! Thanks so much for the thoughts. I think with that context we are even closed to moving forward here.


This section of the R Packages book outlines an approach to solve your problem. In short, you can move such dependencies to Suggests versus Depends in your DESCRIPTION and then consider evaluating conditional on package availability

flor14 commented 10 months ago

Thank you @emilyriederer

Now everything should be passing without notes.

In case a bit of context helps as well, this package is part of a "trilogy". I am developing a Shiny app that reads and visualizes the raster images generated with quadkeyr and a website with all the data analysis necessary for that app. I am actively working on making the three of them coherent now, the idea is to keep the reusable functions in quadkeyr to ensure reproducibility and make them available for future projects (or anyone that might process similar data).

I hope you have happy holidays

emilyriederer commented 10 months ago

@ropensci-review-bot check package

ropensci-review-bot commented 10 months ago

Thanks, about to send the query.

ropensci-review-bot commented 10 months ago

:rocket:

Editor check started

:wave:

emilyriederer commented 10 months ago

Hi @flor14 - thank you so much for the note and for these updates! The package looks in great shape to share with reviewers. I already have one strong lead and will commence looking for another. Happy holidays and we will be in touch!

emilyriederer commented 10 months ago

Editor checks:

Editor comments

This package seems very well-motivated and well-polished for reviewers. The other nice-to-haves on pkgdown might be:

However, these are both very minor points and neither is an impediment to moving forward with the review


emilyriederer commented 10 months ago

@ropensci-review-bot seeking reviewers

ropensci-review-bot commented 10 months ago

Please add this badge to the README of your package repository:

[![Status at rOpenSci Software Peer Review](https://badges.ropensci.org/619_status.svg)](https://github.com/ropensci/software-review/issues/619)

Furthermore, if your package does not have a NEWS.md file yet, please create one to capture the changes made during the review process. See https://devguide.ropensci.org/releasing.html#news

ropensci-review-bot commented 10 months ago

Checks for quadkeyr (v0.0.0.9000)

git hash: f47d2345

(Checks marked with :eyes: may be optionally addressed.)

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 | 133| |internal |quadkeyr | 48| |internal |utils | 35| |internal |graphics | 3| |internal |stats | 1| |imports |sf | 10| |imports |dplyr | 9| |imports |stars | 3| |imports |purrr | 1| |imports |lubridate | NA| |imports |readr | NA| |imports |rlang | NA| |imports |shiny | NA| |suggests |bslib | NA| |suggests |DT | NA| |suggests |ggplot2 | NA| |suggests |knitr | NA| |suggests |leaflet | NA| |suggests |rmarkdown | NA| |suggests |rnaturalearth | NA| |suggests |shinytest2 | NA| |suggests |testthat | NA| |suggests |tidyr | NA| |suggests |viridis | 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

list (18), return (18), c (16), for (11), data.frame (9), nrow (5), seq_len (5), min (3), nchar (3), pi (3), seq (3), sign (3), abs (2), as.integer (2), by (2), file (2), floor (2), max (2), rbind (2), sum (2), unique (2), as.character (1), as.Date (1), as.numeric (1), atan (1), character (1), colnames (1), exp (1), is.na (1), length (1), list.files (1), log (1), paste0 (1), rev (1), seq_along (1), sin (1), strsplit (1), subset (1), system.file (1)

quadkeyr

clip (7), mapsize (6), missing_combinations (3), pixelXY_to_latlong (3), pixelXY_to_tileXY (3), quadkey_to_tileXY (3), complete_grid_for_polygons (2), create_qk_grid (2), create_raster (2), latlong_to_pixelXY (2), quadkey_to_latlong (2), tileXY_to_pixelXY (2), apply_weekly_lag (1), extract_qk_coord (1), extract_tile_coord (1), format_data (1), grid_to_polygon (1), ground_res (1), latlong_to_quadkey (1), mapscale (1), polygon_to_raster (1), qkmap_app (1), tileXY_to_quadkey (1)

utils

data (35)

sf

st_as_sf (6), st_bbox (2), st_sf (2)

dplyr

mutate (5), anti_join (2), all_of (1), lag (1)

graphics

grid (3)

stars

st_as_stars (1), st_rasterize (1), write_stars (1)

purrr

map_dfr (1)

stats

var (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 13 files) and - 1 authors - 3 vignettes - 2 internal data files - 8 imported packages - 25 exported functions (median 12 lines of code) - 27 non-exported functions in R (median 27 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 | 13| 68.2| | |files_vignettes | 3| 92.4| | |files_tests | 14| 93.8| | |loc_R | 448| 44.1| | |loc_vignettes | 450| 75.5| | |loc_tests | 424| 71.6| | |num_vignettes | 3| 94.2| | |data_size_total | 2037768| 97.7|TRUE | |data_size_median | 1018884| 98.5|TRUE | |n_fns_r | 52| 57.9| | |n_fns_r_exported | 25| 73.6| | |n_fns_r_not_exported | 27| 49.7| | |n_fns_per_file_r | 2| 34.7| | |num_params_per_fn | 2| 11.9| | |loc_per_fn_r | 18| 56.7| | |loc_per_fn_r_exp | 12| 27.7| | |loc_per_fn_r_not_exp | 27| 74.8| | |rel_whitespace_R | 51| 74.2| | |rel_whitespace_vignettes | 37| 80.0| | |rel_whitespace_tests | 29| 76.2| | |doclines_per_fn_exp | 21| 15.7| | |doclines_per_fn_not_exp | 0| 0.0|TRUE | |fn_call_network_size | 46| 64.6| | ---

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 [![pkgcheck.yaml](https://github.com/Fernandez-Lab-WSU/quadkeyr/actions/workflows/pkgcheck.yaml/badge.svg)](https://github.com/Fernandez-Lab-WSU/quadkeyr/actions) [![check-standard.yaml](https://github.com/Fernandez-Lab-WSU/quadkeyr/actions/workflows/check-standard.yaml/badge.svg)](https://github.com/Fernandez-Lab-WSU/quadkeyr/actions) **GitHub Workflow Results** | id|name |conclusion |sha | run_number|date | |----------:|:--------------------------|:----------|:------|----------:|:----------| | 7304730378|pages build and deployment |success |5cd150 | 30|2023-12-22 | | 7304720785|pkgcheck |success |45340a | 10|2023-12-22 | | 7304720781|pkgdown |success |45340a | 30|2023-12-22 | | 7304720784|R-CMD-check |success |45340a | 12|2023-12-22 | | 7304720782|test-coverage |success |45340a | 30|2023-12-22 | --- #### 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: 83.9 #### Cyclocomplexity with [cyclocomp](https://github.com/MangoTheCat/cyclocomp) The following function have cyclocomplexity >= 15: function | cyclocomplexity --- | --- create_qk_grid | 18 #### Static code analyses with [lintr](https://github.com/jimhester/lintr) [lintr](https://github.com/jimhester/lintr) found the following 47 potential issues: message | number of times --- | --- Avoid library() and require() calls in packages | 15 Lines should not be more than 80 characters. | 11 Use <-, not =, for assignment. | 21


4. Other Checks

Details of other checks (click to open)

:heavy_multiplication_x: The following 3 function names are duplicated in other packages: - - `clip` from CUFF, ramify - - `create_raster` from SpatialKDE - - `format_data` from GCalcium, popbayes


Package Versions

|package |version | |:--------|:--------| |pkgstats |0.1.3.9 | |pkgcheck |0.1.2.11 |


Editor-in-Chief Instructions:

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

emilyriederer commented 10 months ago

@ropensci-review-bot add @mpaulacaldas as reviewer

ropensci-review-bot commented 10 months ago

@mpaulacaldas added to the reviewers list. Review due date is 2024-01-16. Thanks @mpaulacaldas 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 10 months ago

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

emilyriederer commented 10 months ago

Hi @flor14 - I'm delighted to introduct @mpaulacaldas as our first reviewer. Maria has substantial experience in geospatial analysis and R package development, including with quadkey datasets, so she will bring a fantastic perspective. I'm still seeking a second reviewer

mpaulacaldas commented 10 months ago

Hi @emilyriederer and @flor14! I'm very happy to help with this review. I take note of the 2024-01-16 deadline, and will write back in the coming days

emilyriederer commented 10 months ago

Thank you, @mpaulacaldas ! That said, our hardworking bot doesn't know that it's the holidays, and I know for many this isn't a typical workweek. Given that (and that I still need one more reviewer!) please feel free to take an extra week if needed 🙂

flor14 commented 10 months ago

Thank you @mpaulacaldas for being a reviewer. It is great that you have used quadkeys before, I hope the package is useful and of interest!

emilyriederer commented 10 months ago

Hi @flor14 - I'm please to introduce our second reviewer @vincentvanhees. Dr. Van Hees is an experienced R developer and consultant who was previously written and maintained geospatial R packages. I think this experience will bring great insights to the quadkeyr review

emilyriederer commented 10 months ago

@ropensci-review-bot add @vincentvanhees as reviewer

ropensci-review-bot commented 10 months ago

@vincentvanhees added to the reviewers list. Review due date is 2024-01-20. Thanks @vincentvanhees 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 10 months ago

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

vincentvanhees commented 10 months ago

Here is my review :) Let me know if anything is unclear.

Documentation

The package includes all the following forms of documentation:

Functionality

Estimated hours spent reviewing: 3


Review Comments

I enjoyed reviewing this package, it is well designed. Even though raster data and quadkeys are not my expertise, I was able to figure out what the package is doing.

1. Vignettes and README:

current filename new title new filename
create_rasters_from_grid.Rmd From facebook quadkey data to raster from_facebook_quadkey_data_to_raster.Rmd
get_grid_from_quadkeys.Rmd Create your own quadkeys and matching grid and raster create_your_own_quadkeys.Rmd
quadkey_conversion.Rmd Bing Maps Tile System Functions bing_maps_tile_tystem_functions.Rmd

2. R functions:

data[i, c('pixelX', 'pixelY')] <- latlong_to_pixelXY(data$lat[i], 
                                                       data$lon[i],
                                                       data$level[i])
data[i, c('tileX', 'tileY')]  <-  pixelXY_to_tileXY(data$pixelX[i],
                                                    data$pixelY[i])

3. Test function:

4. Shiny app:

5. General / Other comments:

image

6. Suggestions (no need to respond):