Closed hrecht closed 1 year ago
Thanks for the heads-up. My preference would be to add "AK" to the subsequent line (L20) of that file. Getting automated package checking to recognize built-in datasets can be a real pain in my experience.
I feel that pain! It looks like it is working here though? https://github.com/jsta/nhdR/blob/master/R/utils.R#L289 Another option would be to add your own simple dataset of the postal abbreviations and state names, and that could include territories as well. I do something similar for state fips codes in my censusapi package.
Some other U.S. territories that seem to not be recognized but do have NHD state files: American Samoa, Guam, Northern Mariana Islands.
Awesome1 Let's go with your initial suggestion then.
Relevant state/territory code key: https://en.wikipedia.org/wiki/List_of_U.S._state_and_territory_abbreviations
This is working now, thanks for such a quick fix!
Hi, thanks for the great package. I'm trying to get data for Alaska and am getting this error message:
It looks like the issue stems from this line of code. I'm not familiar with the maps library but it seems to not have Alaska in it. https://github.com/jsta/nhdR/blob/master/R/get.R#L19
One solution would be to switch to R's built in
state.abb
dataset plus DC and the territories.