Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

stats19 #266

Closed
14 of 19 tasks
Robinlovelace opened this issue Nov 23, 2018 · 83 comments
Closed
14 of 19 tasks

stats19 #266

Robinlovelace opened this issue Nov 23, 2018 · 83 comments

Comments

@Robinlovelace
Copy link
Member

Robinlovelace commented Nov 23, 2018

Summary

  • What does this package do? (explain in 50 words or less):

The goal of stats19 is to make it easy to work with road crash data. Specifically it enables access to and processing of the UK’s official road traffic casualty database, which is called STATS19.

  • Paste the full DESCRIPTION file inside a code block below:
Package: stats19
Title: Work with open road traffic casualty data from Great Britain
Version: 0.1.0.9000
Authors@R: c(
    person("Robin", "Lovelace", email = "rob00x@gmail.com", role = c("aut", "cre"),
    comment = c(ORCID = "0000-0001-5679-6536")),
    person("Malcolm", "Morgan", email = "m.morgan1@leeds.ac.uk", role = c("aut")),
    person("Layik", "Hama", email = "layik.hama@gmail.com", role = c("aut"))
  )
Description: Tools to help process and analysie the UK road collision data also known as Stats19.
Depends: R (>= 3.5.0)
License: GPL-3
Encoding: UTF-8
LazyData: true
Imports: 
    sf,
    foreign,
    readr,
    dplyr,
    lubridate,
    readxl
Suggests: 
    knitr,
    rmarkdown,
    testthat
VignetteBuilder: knitr
RoxygenNote: 6.1.1
  • URL for the package (the development repository, not a stylized html page): https://github.com/ITSLeeds/stats19

  • Please indicate which category or categories from our package fit policies this package falls under *and why(? (e.g., data retrieval, reproducibility. If you are unsure, we suggest you make a pre-submission inquiry.):

  • data retrieval: downloads and formats publicly available road safety data that is difficult (impossible for most people) to use effectively without

  •   Who is the target audience and what are scientific applications of this package?  

Academic, industry and public sector researchers investigating road safety, specifically people wanting to perform natural experimental studies to find out how best to make the transport system safer. It will also be of interest for people interested in large point-on-network data for methodological applications.

Previous packages/code-bases:

  • code in the bikeR repo underlying an academic paper on collisions involving cyclists
  • functions in stplanr for downloading Stats19 data
  • updated functions related to the CyIPT project

but this package takes the best of the preceding packages and adds new features including:

  • automated and reproducible data formatting code based on DfT's official guidelines (before labels were hard-coded)

  • continuous integration

  • integration with sf (the stplanr implementation used sp)

  • inclusion of much more data (back to 1974 and until 2017, previous work only covered 1985:2015)

  •   If you made a pre-submission enquiry, please paste the link to the corresponding issue, forum post, or other discussion, or @tag the editor you contacted.

Requirements

Confirm each of the following by checking the box. This package:

  • does not violate the Terms of Service of any service it interacts with.
  • has a CRAN and OSI accepted license.
  • contains a README with instructions for installing the development version.
  • includes documentation with examples for all functions.
  • contains a vignette with examples of its essential functions and uses.
  • has a test suite.
  • has continuous integration, including reporting of test coverage, using services such as Travis CI, Coveralls and/or CodeCov.
  • I agree to abide by ROpenSci's Code of Conduct during the review process and in maintaining my package should it be accepted.

Publication options

  • Do you intend for this package to go on CRAN?
  • Do you wish to automatically submit to the Journal of Open Source Software? If so:
    • The package has an obvious research application according to JOSS's definition.
    • The package contains a paper.md matching JOSS's requirements with a high-level description in the package root or in inst/.
    • The package is deposited in a long-term repository with the DOI:
    • (Do not submit your package separately to JOSS)
  • Do you wish to submit an Applications Article about your package to Methods in Ecology and Evolution? If so:
    • 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)
    • (Scope: Do consider MEE's Aims and Scope 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)

Detail

  • Does R CMD check (or devtools::check()) succeed? Paste and describe any errors or warnings:

  • Does the package conform to rOpenSci packaging guidelines? Please describe any exceptions:

  • Currently the style uses = assignment, which differs from the recommended style

  • If this is a resubmission following rejection, please explain the change in circumstances:

  • If possible, please provide recommendations of reviewers - those with experience with similar packages and/or likely users of your package - and their GitHub user names:

@sckott sckott added the package label Nov 26, 2018
@sckott
Copy link
Contributor

sckott commented Nov 26, 2018

thanks for your submission @Robinlovelace We are discussing now and will get back to you soon

@Robinlovelace
Copy link
Member Author

Great. It's in active development as you'll see. We have code to make all those millions of crash points sf data frames, we've just not pushed it. @layik has done great work refactoring the download functions so it makes it much easier to access this important dataset. Looking forward to hearing back from you and thanks for the update.

@Robinlovelace
Copy link
Member Author

Heads-up @sckott format_sf() is now in there and the package now has a proper vignette. Are there any other things we should add at this stage for peer review? Thanks.

@sckott
Copy link
Contributor

sckott commented Dec 3, 2018

will dig into it today, i'll let you know

@sckott
Copy link
Contributor

sckott commented Dec 3, 2018

Editor checks:

  • Fit: The package meets criteria for fit and overlap
  • Automated tests: Package has a testing suite and is tested via Travis-CI or another CI service.
  • License: The package has a CRAN or OSI accepted license
  • Repository: The repository link resolves correctly
  • Archive (JOSS only, may be post-review): The repository DOI resolves correctly
  • Version (JOSS only, may be post-review): Does the release version given match the GitHub release (v1.0.0)?

Editor comments

Thanks for your submission @Robinlovelace !

Here's the output from goodpractice. No need to address these now, it's info for reviewers to use to get started.

── GP stats19 ─────────────
It is good practice towrite unit tests for all functions, and all package code in general. 95% of code lines are covered by test cases.

    R/dl_stats19.R:82:NA
    R/dl_stats19.R:83:NA
    R/format.R:55:NA
    R/format.R:106:NA
    R/format.R:157:NA
    ... and 12 more linesadd a "URL" field to DESCRIPTION. It helps users find information about your package online. If your package does not have a homepage, add an URL
    to GitHub, or the CRAN package package page.add a "BugReports" field to DESCRIPTION, and point it to a bug tracker. Many online code hosting services provide bug trackers for free,
    https://github.com, https://gitlab.com, etc.use '<-' for assignment instead of '='. '<-' is the standard, and R users and developers are used it and it is easier to read your code for them if
    you use '<-'.

    R/dl_stats19.R:28:12
    R/dl_stats19.R:30:9
    R/dl_stats19.R:31:16
    R/dl_stats19.R:32:11
    R/dl_stats19.R:34:18
    ... and 204 more linesavoid long code lines, it is bad for readability. Also, many people prefer editor windows that are about 80 characters wide. Try make your lines
    shorter than 80 characters

    R/dl_stats19.R:28:1
    R/dl_stats19.R:104:1
    R/dl_stats19.R:105:1
    R/format.R:42:1
    R/format.R:98:1
    ... and 14 more linesavoid sapply(), it is not type safe. It might return a vector, or a list, depending on the input data. Consider using vapply() instead.

    R/format.R:257:20avoid 1:length(...), 1:nrow(...), 1:ncol(...), 1:NROW(...) and 1:NCOL(...) expressions. They are error prone and result 1:0 if the expression on
    the right hand side is zero. Use seq_len() or seq_along() instead.

    R/format.R:247:11fix this R CMD check NOTE: Namespaces in Imports field not imported from:dplyr’ ‘foreign’ ‘lubridateAll declared Imports should be used.

Seeking reviewers now 🕐


Reviewers:

@Robinlovelace
Copy link
Member Author

Robinlovelace commented Dec 3, 2018

Thanks @sckott. I'd seen goodpractice but never used it - that is very useful. After a few commits stats19 is improved. Latest results:

── GP stats19 ───────────────────────────────────────────────────────────────────────────

It is good practice to

  ✖ write unit tests for all functions, and all package code in
    general. 95% of code lines are covered by test cases.

    R/dl_stats19.R:85:NA
    R/dl_stats19.R:86:NA
    R/format.R:43:NA
    R/format.R:88:NA
    R/format.R:133:NA
    ... and 12 more lines

  ✖ use '<-' for assignment instead of '='. '<-' is the standard, and
    R users and developers are used it and it is easier to read your code for
    them if you use '<-'.

    R/dl_stats19.R:28:12
    R/dl_stats19.R:33:9
    R/dl_stats19.R:34:16
    R/dl_stats19.R:35:11
    R/dl_stats19.R:37:18
    ... and 203 more lines

@sckott
Copy link
Contributor

sckott commented Dec 7, 2018

Reviewers assigned:

@daranzolin
Copy link
Member

daranzolin commented Dec 9, 2018

Prolegomena

Thanks to rOpenSci for the invitation to review, and special thanks to Robin, Malcolm, Layik, and Mark for this important package. I'm already a huge fan.


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

  • As the reviewer I confirm that there are no conflicts of interest for me to review this work (If you are unsure whether you are in conflict, please speak to your editor before starting your review).

Documentation

The package includes all the following forms of documentation:

  • A statement of need clearly stating problems the software is designed to solve and its target audience in README

I would tease a bit more of what's in these data sets. I wasn't entirely sure until I downloaded and opened the supporting documentation. If I were searching for this kind of data, and I didn't know what STATS19 was, I'd like to know I'm in the right place after scanning the README. Maybe a map?

  • Installation instructions: for the development version of package and any non-standard dependencies in README
  • Vignette(s) demonstrating major functionality that runs successfully locally

I couldn't load the vignette from the console:

vignette(package = "stats19")
#> no vignettes found

Admittedly, I also couldn't load the vignette for my own rOpenSci package, so I'm not sure what's missing.

  • Function Documentation: for all exported functions in R help
  • Examples for all exported functions in R Help that run successfully locally

Several of the examples failed:

  • read_casualties -- argument for dl_stats19 should be year instead of years
  • read_vehicles -- I think year must be specified and presupposes an existing download of Vehicles data, e.g. ve = read_vehicles(year = 2017)
stats19::read_vehicles()
#> Error in if (year %in% 1980:2003) {: argument is of length zero
  • check_input_file -- no example included
  • format_accidents -- same as above, argument for dl_stats19 should be year instead of years
  • format_casualties -- same as above, argument for dl_stats19 should be year instead of years
  • format_vehicles -- same as above, argument for dl_stats19 should be year instead of years
  • format_sf -- read_accidents requires a year argument
  • Community guidelines including contribution guidelines in the README or CONTRIBUTING, and DESCRIPTION with URL, BugReports and Maintainer (which may be autogenerated via Authors@R).

I couldn't find any explicit contributing guidelines in the README, and there is no CONTRIBUTING document.

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).

There is no paper.md.

Functionality

  • Installation: Installation succeeds as documented.
  • Functionality: Any functional claims of the software been confirmed.
  • Performance: Any performance claims of the software been confirmed.
  • Automated tests: Unit tests cover essential functions of the package
    and a reasonable range of inputs and conditions. All tests pass on the local machine.

Test results:

══ Results ═════════════════════════════════════════════════════════════════════════════════════════════════
Duration: 24.2 s

OK:       37
Failed:   0
Warnings: 0
Skipped:  0
  • Packaging guidelines: The package conforms to the rOpenSci packaging guidelines

Final approval (post-review)

  • The author has responded to my review and made changes to my satisfaction. I recommend approving this package.

Estimated hours spent reviewing: 3.5


Review Comments

A superb and essential package--we need this data and we need it in these formats. The download-format-read-explore workflow is intuitive and relatively frictionless. I have only some brief comments:

  • I wonder you could possibly merge the formatting and reading step with a raw = TRUE or format = TRUE argument in the read_* functions. But perhaps that's my tendency towards abstraction. Something like ac = read_accidents(year = 2017, format = TRUE)

  • My personal preference would be to have the schema from dl_schema lazily loaded with the package.

  • According to the vignette, the dl_* functions are interactive, although the interactivity is commented out in the code. Will the interactivity be returning? Or does the vignette need to be updated?

  • Out of curiosity, what's happening with https://github.com/cyipt/stats19? It was updated recently.

  • I confess I wish the package name was more expressive--stats19 sounds like an introductory statistics class.

  • This data will be used to make many maps. I personally would love a nudge in that direction in either the README or the vignette.

@sckott
Copy link
Contributor

sckott commented Dec 10, 2018

thanks very much for your review @daranzolin

@mpadge
Copy link
Member

mpadge commented Dec 11, 2018

Yeah, thanks @daranzolin for an impressively prompt review. I'll leave the response proper to @layik and @Robinlovelace, but will confess guilty here to having commented out the interactivity in the dl_* functions. That's all my doing and I should already have reinstated it. Apologies to all, and yes, it will be returning.

@Robinlovelace
Copy link
Member Author

Many thanks for the quick yet detailed review @daranzolin. I'm working on it this week and will get back to you on each of those constructive comments asap. More soon...

@layik
Copy link
Member

layik commented Dec 11, 2018

Great review @daranzolin. Appreciate it. Thanks @Robinlovelace and @mpadge. Apologies I just missed this thread for some reason.

@Robinlovelace
Copy link
Member Author

Heads-up all (especially @daranzolin, @mpadge and @layik - the originator of interactive downloads in stats19), I've re-added interactivity, this time using menu() which is best practice for this kind of thing and fewer lines of code.

Please check out the video to see how it works here:

asciicast

And if you're interested in the code used to do this, see here: https://github.com/ITSLeeds/stats19/pull/36

Feedback on behaviour or code welcome before I merge this. Many thanks @layik for implementing this 1st time around.

@layik
Copy link
Member

layik commented Dec 17, 2018

Just going through the review @daranzolin, RE vignette, I think what you needed to do was

devtools::install(build_vignettes = TRUE)

then you would be able to load the vignette.

@Robinlovelace
Copy link
Member Author

Heads-up we've addressed most of the issues raised by @daranzolin I think. Many thanks for a great set of comments. We're documenting them here https://github.com/ITSLeeds/stats19/issues/49 and plan to put the review responses here https://github.com/ITSLeeds/stats19/blob/master/responses1.Rmd

Not quite finished but plan to properly respond in a comment here by Saturday this week - sorry it's taken a while.

@layik
Copy link
Member

layik commented Dec 20, 2018

Hi @daranzolin, as promised by @Robinlovelace find our responses and thank you very much for taking time to do the review and please feel free to let us know if you have any further feedback.

=====

Responses to review 1 of stats19

Thanks for the review. We've had a chance, after making some changes and fixes to the package, to take-in and act on each of the comments. The code-base has evolved substantially since the review, but the fundamental design of the package, with its 3 stage API mirroring workflows that happened before the package was developed, remains unchanged. That is:

  • dl_stats19() downloads files from the DfT. Good news: we have spoken to the relevant people at the Department for Transport and they assured us that the endpoints are stable. The function now uses menu() to provide a menu of download options for any year/type combinations and now finds files outside those explicitly mentioned in the file names. E.g.:
dl_stats19(year = 2017)
# Multiple matches. Which do you want to download?
# 
# 1: dftRoadSafetyData_Vehicles_2017.zip
# 2: dftRoadSafetyData_Casualties_2017.zip
# 3: dftRoadSafetyData_Accidents_2017.zip
dl_stats19(year = 2017, type = "ac")
# Files identified: dftRoadSafetyData_Accidents_2017.zip
# 
# Wanna do it (y = enter, n = esc)? 
dl_stats19(year = 1985)
# Year not in range, changing to match 1979:2004 data
# This file is over 240 MB in size.
# Once unzipped it is over 1.8 GB.
# Files identified: Stats19-Data1979-2004.zip
# 
# Wanna do it (y = enter, n = esc)?
  • read_*() these functions remain unchanged, except the order of arguments has changed. Like dl_stats19(), year is now the first argument, which is more intuitive.

  • format_*() functions have been refactored. Each now uses format_stats19() behind the scenes reducing duplication. The results are now better: more variables are now labelled.

Note: the last two stages is now combined by default as per this review read_*(format = TRUE) by default.

We'll focus on areas flagged in the review for the rest of this response:

I would tease a bit more of what's in these data sets. I wasn't entirely sure until I downloaded and opened the supporting documentation. If I were searching for this kind of data, and I didn't know what STATS19 was, I'd like to know I'm in the right place after scanning the README. Maybe a map?

We have added a map (well technically 9 maps!) and a couple of time series plots showing the scale of the data. Also show a sample of the additional casualty and vehicle tables has been added to show more clearly the richness of data provided.

I couldn't load the vignette from the console:

We also could not see the vignette when installing using devtools::install_github(build_vignettes = TRUE. But we can see the vignette if we install locally.

This was the code we ran:

devtools::install(build_vignettes = TRUE)
## Installing stats19
vignette(package = "stats19")

Several of the examples failed:

These have now been fixed - thanks for testing and reporting.

I couldn't find any explicit contributing guidelines in the README, and there is no CONTRIBUTING document.

A CONTRIBUTING is added now. Thank you.

The package has an obvious research application according to JOSS's definition

There is no paper.md.

One is added 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).

Review Comments

A superb and essential package--we need this data and we need it in these formats. The download-format-read-explore workflow is intuitive and relatively frictionless. I have only some brief comments:

Thank you.

I wonder you could possibly merge the formatting and reading step with a raw = TRUE or format = TRUE argument in the read_* functions. But perhaps that's my tendency towards abstraction. Something like ac = read_accidents(year = 2017, format = TRUE)

Done, appreciate your input.

My personal preference would be to have the schema from dl_schema lazily loaded with the package.

DESCRIPTION: has the line LazyData which means stats19_schema is lazy loaded.

According to the vignette, the dl_* functions are interactive, although the interactivity is commented out in the code. Will the interactivity be returning? Or does the vignette need to be updated?

Back in, as stated above.

Out of curiosity, what's happening with https://github.com/cyipt/stats19? It was updated recently.

@mem48 answered this: cyipt/stats19 is not actually a proper R package. It is a repo containing scripts for CyIPT project, it has different sources (UK DS), and usage so there is no current need to adapt the use to this package. Malcolm is one of the contributors to this package.

I confess I wish the package name was more expressive--stats19 sounds like an introductory statistics class.

This a reasonable point that we have thought of and discussed. We are open minded about changing the name but, as with so many things, there are +s and -s (outlined for some options below):

  • stats19data

    • clarifies that it's about data
    • longer, suffers from some of the same issues that stats19 suffers from, the package is more about data formatting than data provision
  • roadcrashesUK

    • explicit, makes region of data access transparent
    • there are other types of road crash data, also the data currently provided is technically for Great Britain, but roadcrashesGB doesn't work so well, and we may want to add data access options for Northern Ireland at some point also
  • roadSafetyData

    • Matches DfT's webpage title on the topic
    • longer and, again, is less specific.

The main benefit we can see of changing the name would be making the package easier to find. We think good documentation and clear description and some write-ups of the package and what it does could address these issues. We've explored stat19 name and it links directly to (and is almost synonymous with) road crash data. See https://en.wikipedia.org/wiki/STATS19 for an excellent example (we plan to add this link to the README)

so the name is OK for we think, but we're open minded to alternative names mentioned above and perhaps names we've not thought of.

This data will be used to make many maps. I personally would love a nudge in that direction in either the README or the vignette.

Definitely. Thank you very much for your input.

@Robinlovelace
Copy link
Member Author

Robinlovelace commented Dec 20, 2018

Quick question for @sckott, what is you policy regarding CRAN submission while it's under review? We may change this in response the the answer (or we submit tomorrow!): https://github.com/ITSLeeds/stats19/milestone/1.

Look forward to your response @adamhsparks.

@stefaniebutland
Copy link
Member

Sounds great! I'll mark my calendar

@Robinlovelace
Copy link
Member Author

Heads-up @sckott I've submitted the package to CRAN and have added a Zenodo DOI badge as suggested. I've also submitted the package to JOSS for peer review. Next steps? Starting some work that may cite the package so will useful to have a 'cannonical' .bib file also.

@sckott
Copy link
Contributor

sckott commented Jan 15, 2019

sounds good @Robinlovelace that's it. will close issue now. yeah, having a citation file is a good idea

@sckott sckott closed this as completed Jan 15, 2019
@Robinlovelace
Copy link
Member Author

Fantastic! What is best practice when creating a CITATION file? I can see how to create it from the official documentation here: https://cran.r-project.org/doc/manuals/R-exts.html#CITATION-files

But see that some packages, such as dplyr and drake lack one.

@Robinlovelace
Copy link
Member Author

See here for an example of a CITATION file: https://github.com/cran/nlme/tree/master/inst

@sckott
Copy link
Contributor

sckott commented Jan 15, 2019

don't know really. @maelle @cboettig any thoughts on this?

@Robinlovelace
Copy link
Member Author

And also, what is the official citation info of the package? Will it change when it is published in JOSS?

@sckott
Copy link
Contributor

sckott commented Jan 15, 2019

official with respect to?

I think JOSS would be an additional citation you could be put in the citaiton file

@Robinlovelace
Copy link
Member Author

Just 1 citation for the package is probably enough - that's the aim of the CITATION file, I believe, to allow authors to choose what the official citation info is, with respect to the output of citation(). This is a good example from the sf package:

citation("sf")
#> 
#> To cite package sf in publications use:
#> 
#>   Pebesma, E., 2018. Simple Features for R: Standardized Support
#>   for Spatial Vector Data. The R Journal,
#>   https://journal.r-project.org/archive/2018/RJ-2018-009/
#> 
#> A BibTeX entry for LaTeX users is
#> 
#>   @Article{,
#>     author = {Edzer Pebesma},
#>     title = {{Simple Features for R: Standardized Support for Spatial
#>           Vector Data}},
#>     year = {2018},
#>     journal = {{The R Journal}},
#>     url = {https://journal.r-project.org/archive/2018/RJ-2018-009/index.html},
#>   }

Created on 2019-01-15 by the reprex package (v0.2.1)

The associated CITATION file can be found here: https://github.com/r-spatial/sf/blob/master/inst/CITATION

I think it may be useful for authors to have guidance from rOpenSci on this, seeing as you provide really useful guidance on, and state preferences on (no problem with that!) many aspects of package design.

@adamhsparks
Copy link
Member

Here's the approach I've taken with my packages on JOSS. I have one for the paper and one for the package that will always give the version used.

citHeader("While nasapower does not redistribute the data in any way,\n",
          "we encourage users to follow the requests of the POWER\n",
          "Project Team:\n",
          "\n",
          "'When POWER data products are used in a publication, we\n",
          "request the following acknowledgment be included:\n",
          "These data were obtained from the NASA Langley Research\n",
          "Center POWER Project funded through the NASA Earth Science\n",
          "Directorate Applied Science Program.'\n",
          "\n",
          "To cite nasapower in publications, please use:")

citEntry(
  entry = "Article",
  author = as.person("Adam H Sparks"),
  title = "nasapower: A NASA POWER Global Meteorology, Surface Solar Energy and Climatology Data Client for R",
  doi = "10.21105/joss.01035",
  year = 2018,
  month = "oct",
  publisher = "The Open Journal",
  volume = 3,
  number = 30,
  pages = 1035,
  journal = "The Journal of Open Source Software",

  textVersion = paste("Sparks, (2018). nasapower: A NASA POWER Global Meteorology, Surface Solar Energy and Climatology Data Client for R. Journal of Open Source Software, 3(30), 1035, https://doi.org/10.21105/joss.01035"))

year <- sub("-.*", "", meta$Date)
note <- sprintf("R package version %s", meta$Version)

bibentry(bibtype = "Manual",
         title = "{nasapower}: NASA-POWER Data from R",
         author = c(person("Adam", "Sparks")),
         year = year,
         note = note,
	 url = "https://ropensci.github.io/nasapower/")

 textVersion = paste("Adam H Sparks, (", year, ").",
  " nasapower: A NASA POWER Global Meteorology, Surface Solar Energy and Climatology Data Client for R. ",
  note, ".",
  " https://CRAN.R-project.org/package=nasapower", sep = "")

@Robinlovelace
Copy link
Member Author

Many thanks @adamhsparks, very useful. I plan to create something similar to this: https://github.com/ropensci/nasapower/blob/master/inst/CITATION

Worth adding something on CITATION in the package guidance/process?

@stefaniebutland
Copy link
Member

How's early February for an ETA?

Hi @Robinlovelace. Can you suggest a date by which you'd like to submit a draft blog post?

@Robinlovelace
Copy link
Member Author

Robinlovelace commented Feb 6, 2019

Sure, how's a week tomorrow? In other words,

remotes::install_github("ATFutures/calendar")
#> Skipping install of 'calendar' from a github remote, the SHA1 (6c67c0fc) has not changed since last install.
#>   Use `force = TRUE` to force installation
library(calendar)
e = ic_event(start_time = "2019-02-14 10:00", end_time = "2019-02-14 10:00", summary = "Complete stats19 blog post")
e
#> # A tibble: 1 x 4
#>   UID                DTSTART             DTEND               SUMMARY      
#>   <chr>              <dttm>              <dttm>              <chr>        
#> 1 ical-f3df3945-5e5… 2019-02-14 10:00:00 2019-02-14 12:00:00 Complete sta…
class(e)
#> [1] "ical"       "tbl_df"     "tbl"        "data.frame"
ic_write(e, "e.ics")

Created on 2019-02-06 by the reprex package (v0.2.1)

@Robinlovelace
Copy link
Member Author

Resulting Calendar invite (cc @layik ): https://github.com/ATFutures/calendar/releases/download/0.0.1/e.ics

@stefaniebutland
Copy link
Member

Checking in to see if you might have a draft post submitted on Friday. Would love to publish 2019-02-19, but we can publish whenever it's ready

@Robinlovelace
Copy link
Member Author

I think that may be doable...

@Robinlovelace
Copy link
Member Author

Here's the blog post: https://github.com/ropensci/stats19/blob/master/vignettes/blog.Rmd

Any comments/suggestions welcome. Think this is good to go!

@Robinlovelace
Copy link
Member Author

@stefaniebutland one thing: may be worth holding fire: I've just submitted stats19 0.2.0 to CRAN - will be good if the new features are available on the CRAN version when this drops.

@Robinlovelace
Copy link
Member Author

Another update: after some tweaks the article can be found here: https://itsleeds.github.io/stats19/articles/blog.html

@Robinlovelace
Copy link
Member Author

Update: just saw previos messages and am taking a look here https://github.com/ropensci/roweb2#contributing-a-blog-post

@stefaniebutland
Copy link
Member

We can absolutely wait till it's on CRAN.

Thank you for getting the draft done. I'll do a proper review once it's submitted as a pull request (so I can check the technical issues at same time as the content)

@layik
Copy link
Member

layik commented Feb 18, 2019

@Robinlovelace and @stefaniebutland

I have now gone through hugo instructions to get the post ready for a PR. Slight issue with parsing date or maybe that is even expected in dev mode. Only issue is a <script> tag being ignored by hugo or maybe I am not rendering the Rmd properly.

I will send the PR and we can take it from there.

@layik layik mentioned this issue Mar 22, 2019
4 tasks
Robinlovelace added a commit to ropensci/stats19 that referenced this issue Sep 30, 2020
sd 'http://www.pct.bike/' 'https://www.pct.bike/' CONTRIBUTING.md
CRAN-RELEASE
DESCRIPTION
LICENSE.md
NAMESPACE
NEWS.md
R
R/data.R
R/dl.R
R/format.R
R/get.R
R/mot.R
R/read.R
R/stats19-package.R
R/utils.R
README.Rmd
README.md
azure-pipelines.yml
codemeta.json
cran-comments.md
data
data/accidents_sample.rda
data/accidents_sample_raw.rda
data/casualties_sample.rda
data/casualties_sample_raw.rda
data/file_names.rda
data/file_names_old.rda
data/police_boundaries.rda
data/schema_original.rda
data/stats19_schema.rda
data/stats19_variables.rda
data/vehicles_sample.rda
data/vehicles_sample_raw.rda
data-raw
data-raw/README.md
data-raw/misc.Rmd
data-raw/schema.Rmd
inst
inst/2day-slides.Rmd
inst/CITATION
inst/ggtheme-plot.png
inst/iow_example.R
inst/national-cycling-data.R
inst/rstudio-autocomplete.png
inst/stats-19-exercises.Rmd
inst/tmap-zones-interactive.png
inst/ts_example.R
inst/walking-cycling-innovations-slides.Rmd
man
man/accidents_sample.Rd
man/casualties_sample.Rd
man/check_input_file.Rd
man/check_year.Rd
man/dl_stats19.Rd
man/figures
man/figures/README-crash-date-plot-1.png
man/figures/README-crash-time-plot-1.png
man/figures/README-dates-1.png
man/figures/README-ggplot-1.png
man/figures/README-ggplot-ped-severity-1.png
man/figures/README-sfplot-1.png
man/figures/README-sfplot-2.png
man/figures/README-sfplot-3.png
man/figures/README-times-1.png
man/figures/README-unnamed-chunk-2-1.png
man/figures/README-unnamed-chunk-3-1.png
man/figures/logo-500.png
man/figures/logo-800.png
man/figures/logo.png
man/figures/logo.svg
man/file_names.Rd
man/find_file_name.Rd
man/format_accidents.Rd
man/format_casualties.Rd
man/format_column_names.Rd
man/format_ppp.Rd
man/format_sf.Rd
man/format_vehicles.Rd
man/get_MOT.Rd
man/get_data_directory.Rd
man/get_stats19.Rd
man/get_url.Rd
man/locate_files.Rd
man/locate_one_file.Rd
man/phrase.Rd
man/police_boundaries.Rd
man/read_accidents.Rd
man/read_casualties.Rd
man/read_vehicles.Rd
man/schema_original.Rd
man/select_file.Rd
man/set_data_directory.Rd
man/stats19_schema.Rd
man/vehicles_sample.Rd
paper.bib
paper.md
responses1.Rmd
responses2.Rmd
stats19.Rproj
tests
tests/skip-download.R
tests/testthat
tests/testthat/test-data_dir.R
tests/testthat/test-dl_stats19.R
tests/testthat/test-format.R
tests/testthat/test-get.R
tests/testthat/test-mot.R
tests/testthat/test-read_stats19.R
tests/testthat/test-utils.R
tests/testthat.R
updates.sh
vignettes
vignettes/blog.Rmd
vignettes/blog.md
vignettes/blog_files
vignettes/blog_files/figure-markdown_github
vignettes/blog_files/figure-markdown_github/crashes-map-1.png
vignettes/blog_files/figure-markdown_github/nfatalities-1.png
vignettes/blog_files/figure-markdown_github/sfplot-1.png
vignettes/packages.bib
vignettes/references.bib
vignettes/stats19-training-setup.Rmd
vignettes/stats19-training.Rmd
vignettes/stats19-vehicles.Rmd
vignettes/stats19.Rmd
vignettes/wy-overview.jpg
sd 'http://www.r-pkg.org/pkg/stats19' 'https://www.r-pkg.org/pkg/stats19' CONTRIBUTING.md
CRAN-RELEASE
DESCRIPTION
LICENSE.md
NAMESPACE
NEWS.md
R
R/data.R
R/dl.R
R/format.R
R/get.R
R/mot.R
R/read.R
R/stats19-package.R
R/utils.R
README.Rmd
README.md
azure-pipelines.yml
codemeta.json
cran-comments.md
data
data/accidents_sample.rda
data/accidents_sample_raw.rda
data/casualties_sample.rda
data/casualties_sample_raw.rda
data/file_names.rda
data/file_names_old.rda
data/police_boundaries.rda
data/schema_original.rda
data/stats19_schema.rda
data/stats19_variables.rda
data/vehicles_sample.rda
data/vehicles_sample_raw.rda
data-raw
data-raw/README.md
data-raw/misc.Rmd
data-raw/schema.Rmd
inst
inst/2day-slides.Rmd
inst/CITATION
inst/ggtheme-plot.png
inst/iow_example.R
inst/national-cycling-data.R
inst/rstudio-autocomplete.png
inst/stats-19-exercises.Rmd
inst/tmap-zones-interactive.png
inst/ts_example.R
inst/walking-cycling-innovations-slides.Rmd
man
man/accidents_sample.Rd
man/casualties_sample.Rd
man/check_input_file.Rd
man/check_year.Rd
man/dl_stats19.Rd
man/figures
man/figures/README-crash-date-plot-1.png
man/figures/README-crash-time-plot-1.png
man/figures/README-dates-1.png
man/figures/README-ggplot-1.png
man/figures/README-ggplot-ped-severity-1.png
man/figures/README-sfplot-1.png
man/figures/README-sfplot-2.png
man/figures/README-sfplot-3.png
man/figures/README-times-1.png
man/figures/README-unnamed-chunk-2-1.png
man/figures/README-unnamed-chunk-3-1.png
man/figures/logo-500.png
man/figures/logo-800.png
man/figures/logo.png
man/figures/logo.svg
man/file_names.Rd
man/find_file_name.Rd
man/format_accidents.Rd
man/format_casualties.Rd
man/format_column_names.Rd
man/format_ppp.Rd
man/format_sf.Rd
man/format_vehicles.Rd
man/get_MOT.Rd
man/get_data_directory.Rd
man/get_stats19.Rd
man/get_url.Rd
man/locate_files.Rd
man/locate_one_file.Rd
man/phrase.Rd
man/police_boundaries.Rd
man/read_accidents.Rd
man/read_casualties.Rd
man/read_vehicles.Rd
man/schema_original.Rd
man/select_file.Rd
man/set_data_directory.Rd
man/stats19_schema.Rd
man/vehicles_sample.Rd
paper.bib
paper.md
responses1.Rmd
responses2.Rmd
stats19.Rproj
tests
tests/skip-download.R
tests/testthat
tests/testthat/test-data_dir.R
tests/testthat/test-dl_stats19.R
tests/testthat/test-format.R
tests/testthat/test-get.R
tests/testthat/test-mot.R
tests/testthat/test-read_stats19.R
tests/testthat/test-utils.R
tests/testthat.R
updates.sh
vignettes
vignettes/blog.Rmd
vignettes/blog.md
vignettes/blog_files
vignettes/blog_files/figure-markdown_github
vignettes/blog_files/figure-markdown_github/crashes-map-1.png
vignettes/blog_files/figure-markdown_github/nfatalities-1.png
vignettes/blog_files/figure-markdown_github/sfplot-1.png
vignettes/packages.bib
vignettes/references.bib
vignettes/stats19-training-setup.Rmd
vignettes/stats19-training.Rmd
vignettes/stats19-vehicles.Rmd
vignettes/stats19.Rmd
vignettes/wy-overview.jpg
sd 'ropensci/software-review#266' 'ropensci/software-review#266' CONTRIBUTING.md
CRAN-RELEASE
DESCRIPTION
LICENSE.md
NAMESPACE
NEWS.md
R
R/data.R
R/dl.R
R/format.R
R/get.R
R/mot.R
R/read.R
R/stats19-package.R
R/utils.R
README.Rmd
README.md
azure-pipelines.yml
codemeta.json
cran-comments.md
data
data/accidents_sample.rda
data/accidents_sample_raw.rda
data/casualties_sample.rda
data/casualties_sample_raw.rda
data/file_names.rda
data/file_names_old.rda
data/police_boundaries.rda
data/schema_original.rda
data/stats19_schema.rda
data/stats19_variables.rda
data/vehicles_sample.rda
data/vehicles_sample_raw.rda
data-raw
data-raw/README.md
data-raw/misc.Rmd
data-raw/schema.Rmd
inst
inst/2day-slides.Rmd
inst/CITATION
inst/ggtheme-plot.png
inst/iow_example.R
inst/national-cycling-data.R
inst/rstudio-autocomplete.png
inst/stats-19-exercises.Rmd
inst/tmap-zones-interactive.png
inst/ts_example.R
inst/walking-cycling-innovations-slides.Rmd
man
man/accidents_sample.Rd
man/casualties_sample.Rd
man/check_input_file.Rd
man/check_year.Rd
man/dl_stats19.Rd
man/figures
man/figures/README-crash-date-plot-1.png
man/figures/README-crash-time-plot-1.png
man/figures/README-dates-1.png
man/figures/README-ggplot-1.png
man/figures/README-ggplot-ped-severity-1.png
man/figures/README-sfplot-1.png
man/figures/README-sfplot-2.png
man/figures/README-sfplot-3.png
man/figures/README-times-1.png
man/figures/README-unnamed-chunk-2-1.png
man/figures/README-unnamed-chunk-3-1.png
man/figures/logo-500.png
man/figures/logo-800.png
man/figures/logo.png
man/figures/logo.svg
man/file_names.Rd
man/find_file_name.Rd
man/format_accidents.Rd
man/format_casualties.Rd
man/format_column_names.Rd
man/format_ppp.Rd
man/format_sf.Rd
man/format_vehicles.Rd
man/get_MOT.Rd
man/get_data_directory.Rd
man/get_stats19.Rd
man/get_url.Rd
man/locate_files.Rd
man/locate_one_file.Rd
man/phrase.Rd
man/police_boundaries.Rd
man/read_accidents.Rd
man/read_casualties.Rd
man/read_vehicles.Rd
man/schema_original.Rd
man/select_file.Rd
man/set_data_directory.Rd
man/stats19_schema.Rd
man/vehicles_sample.Rd
paper.bib
paper.md
responses1.Rmd
responses2.Rmd
stats19.Rproj
tests
tests/skip-download.R
tests/testthat
tests/testthat/test-data_dir.R
tests/testthat/test-dl_stats19.R
tests/testthat/test-format.R
tests/testthat/test-get.R
tests/testthat/test-mot.R
tests/testthat/test-read_stats19.R
tests/testthat/test-utils.R
tests/testthat.R
updates.sh
vignettes
vignettes/blog.Rmd
vignettes/blog.md
vignettes/blog_files
vignettes/blog_files/figure-markdown_github
vignettes/blog_files/figure-markdown_github/crashes-map-1.png
vignettes/blog_files/figure-markdown_github/nfatalities-1.png
vignettes/blog_files/figure-markdown_github/sfplot-1.png
vignettes/packages.bib
vignettes/references.bib
vignettes/stats19-training-setup.Rmd
vignettes/stats19-training.Rmd
vignettes/stats19-vehicles.Rmd
vignettes/stats19.Rmd
vignettes/wy-overview.jpg
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants