UBC-MDS / software-review-2021

1 stars 1 forks source link

Submission: noaastnr (R) #29

Open chenzhao2020 opened 3 years ago

chenzhao2020 commented 3 years ago

Submitting Author: Chen Zhao (@chenzhao2020) Other Authors: Chirag Rank (@chiragrank), Steffen Pentelow (@spentelow) Repository: noaastnr Version submitted: 0.3.1 Editor: Tiffany Timbers Reviewers: TBD

Archive: TBD Version accepted: TBD


Package: noaastnr
Title: R Package that Downloads, Processes and Visualizes Weather Data from NOAA Website
Version: 0.3.1
Authors@R: 
    c(person(given = "Chen",
           family = "Zhao",
           role = c("aut", "cre"),
           email = "cz2020@student.ubc.ca"),
      person(given = "Chirag",
           family = "Rank",
           role = "aut"),
      person(given = "Steffen",
           family = "Pentelow",
           role = "aut"))
Description: The US National Oceanic and Atmospheric Administration (NOAA) collects and provides access to weather data from land-based weather stations within the US and around the world. One method for accessing these data is through a publically accessible FTP site.  This package allows users to easily download data from a given station for a given year, extract several key weather parameters from the raw data files, and visualize the variation in these parameters over time. 
License: MIT + file LICENSE
Encoding: UTF-8
LazyData: true
Roxygen: list(markdown = TRUE)
RoxygenNote: 7.1.1
Suggests:
    testthat (>= 3.0.0),
    covr,
    knitr,
    rmarkdown
Config/testthat/edition: 3
URL: https://github.com/UBC-MDS/noaastnr
BugReports: https://github.com/UBC-MDS/noaastnr/issues
Imports: 
    curl,
    stringr,
    lubridate,
    dplyr,
    tibble,
    ggplot2,
    tidyr,
    rlang,
    readr,
    utils
VignetteBuilder: knitr

Scope

This package allows users to download and retrieve data from the US National Oceanic and Atmospheric Administration (NOAA) website, carries out data mungling by extracting and cleaning weather parameters, and visualizes the variation in these parameters over time.

The target audience would be anyone who is interested in learning about and analyzing weather data. This package could benefit scientific projects that need an tool to obtain historical weather data from the NOAA's FTP site, and process and visualize key weather parameters.

The package rnoaa provides extensive functionality for interfacing with the NOAA's data systems including their APIs and FTP service. The noaastnr package is a lightweight alternative to the rnoaa package which provides access to a specific subset of NOAA data, namely, their Integrated Surface Database (historical global hourly weather data) through their FTP service.

Tiffany Timbers (@ttimbers)

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

dbandrews commented 3 years ago

Package Review

Please check off boxes as applicable, and elaborate in comments below. Your review is not limited to these topics, as described in the reviewer guide

Documentation

The package includes all the following forms of documentation:

For packages co-submitting to JOSS

The package contains a paper.md matching JOSS's requirements with:

  • [ ] A short summary describing the high-level functionality of the software
  • [ ] Authors: A list of authors with their affiliations
  • [ ] A statement of need clearly stating problems the software is designed to solve and its target audience.
  • [ ] References: with DOIs for all those that have one (e.g. papers, datasets, software).

Functionality

Estimated hours spent reviewing: 3


Review Comments

Hi Chirag, Steffen and Chen - great work on this package! I really like the abstraction and quick introduction to accessing weather observations from all over the world. I can definitely see myself using this for some personal projects with weather related data.

I found the package structure was spot on - testing coverage looks really thorough as well.

Functionality

I haven't checked the Functionality box due to one small issue with using the time_basis="daily" in plot_weather_data. The issue can be reproduced with nearly the example given in the vignette:

library(noaastnr)
weather_data <- get_weather_data("911650-22536", 2020)
plot_weather_data(weather_data, col_name="air_temp", time_basis = "daily")

Which produces:

Error in as.Date.default(date) : 
  do not know how to convert 'date' to class “Date”

I believe the solution should just be changing month to date on this line

I think the tests are missing this because they aren't rendering the objects which would cause ggplot2 to evaluate the objects mapped in the graph. You could look at using vdiffr to do visual regression tests to catch this plus other errors that may come up - I find it not too painful to use and it locks in desired visuals pretty well. Send me a message if you want more info.

Code suggestions

Otherwise I noticed a few things that could potentially be tweaked to speed things up / reduce duplication if you wanted.

Typos/Documentation

There are just a few typos in your README - The "Dependancies" section header, and "publically" in your opening paragraph. In your vignette, you also reference the plot_weather_data function returning an Altair object.


Thanks for making this package! I think the open source weather/geospatial space is really exciting and this package is a welcome addition to quickly grab data from nearby stations. The links to NOAA's weather station GIS portal is a welcome addition as well and helped me poke around what is available. Let me know if you have any questions or thoughts -

Dustin

kmoravej commented 3 years ago

Package Review

Please check off boxes as applicable, and elaborate in comments below. Your review is not limited to these topics, as described in the reviewer guide

Documentation

The package includes all the following forms of documentation:

For packages co-submitting to JOSS

The package contains a paper.md matching JOSS's requirements with:

  • [ ] A short summary describing the high-level functionality of the software
  • [ ] Authors: A list of authors with their affiliations
  • [ ] A statement of need clearly stating problems the software is designed to solve and its target audience.
  • [ ] References: with DOIs for all those that have one (e.g. papers, datasets, software).

Functionality

Estimated hours spent reviewing: 3


Review Comments

Hi Noaastnr team,

Congratulation! You have come up with a great idea and very well structured package. I'm sure it would useful for so many people outside of the MDS. Your code is very easy to follow and readable, Great Job. I have couple of suggestions for you that you may consider:

  df <-
      dplyr::group_by(df, date = lubridate::floor_date(datetime, "day"))

daily

The function returns an Altair chart object which can be saved or displayed in any environment which can render Altair objects.

Great Job! I really enjoyed going through your package and I have learned something new as well. All the best, Kamal

chenzhao2020 commented 3 years ago

Hello @dbandrews and @kmoravej , thank you so much for your comments, those are really helpful. Our team has discussed all the issues you mentioned, and we are going to address them as best as we can. Will keep you updated about our progress. Thanks again for your valuable feedbacks and help!

chenzhao2020 commented 3 years ago

Thank you @dbandrews and @kmoravej for the helpful reviews! We have addressed the changes based on your suggestions in the latest pull requests. The details are as follows:

Other fixes:

Please feel free to check them out. Let us know if you have any more suggestions or advices. Thank you very much!