timtrice / HURDAT

HURDAT is a dataset of best-track analysis for Atlantic and NE Pacific cyclones. This R package scrapes and parses that dataset.
https://hurdat.timtrice.net/
Other
11 stars 4 forks source link

get_hurdat error #6

Closed SwampThingPaul closed 3 years ago

SwampThingPaul commented 3 years ago

Hi @timtrice, I noticed the HURDAT library was no longer on CRAN and when I run get_hurdat(basin=c("AL")) I get the error below.

Error in regexpr(regex, string, perl = TRUE) : 
  invalid regular expression '([:alpha:]{2}[:digit:]{6}),\s+([[:upper:][:digit:]-]+)\s*,\s+([:digit:]+),'
In addition: Warning message:
In regexpr(regex, string, perl = TRUE) : PCRE pattern compilation error
    'POSIX named classes are supported only within a class'
    at '[:alpha:]{2}[:digit:]{6}),\s+([[:upper:][:digit:]-]+)\s*,\s+([:digit:]+),'

Wondering if you have encountered something similar? I am wondering if something with the NOAA source changed?

DaveEslinger commented 3 years ago

Hi Paul, The issue is related to changes in the tidyr package. If you download the HURDAT version from the pull request from Hadley Wickem, (https://github.com/timtrice/HURDAT/pull/5) you'll have a version that you can build and use. It compiled and ran for me with no issues. I think it just needs to be pulled into the main code and then it should pass the CRAN checks.

timtrice commented 3 years ago

Release 0.2.3.2 incorporates #5. This version is also now back in CRAN..

Thank you both for your patience.