EDIorg / EMLassemblyline

R package for creating EML metadata
https://ediorg.github.io/EMLassemblyline/
MIT License
27 stars 13 forks source link

template_geographic_coverage requires a character vector for site.col #121

Closed RobLBaker closed 1 year ago

RobLBaker commented 1 year ago

Currently if the site names in site.col are integers (1, 2, 3, 4, ... N) the following error occurs:

Templating geographic coverage ... geographic_coverage.txt Error in enc2utf8(site_out) : argument is not a character vector

Is it possible to either allow template_georaphic_coverage to work with integers or give the function an option to force R to read the site column as characters rather than defaulting to integers?

clnsmth commented 1 year ago

Thanks for reporting this bug @RobLBaker. I like your idea of allowing template_geographic_coverage() to accept integers (and doubles). This is a simple fix and I should be able to get it out tomorrow.

clnsmth commented 1 year ago

@RobLBaker The fix is in branch 121-geocov-sitecol. Please give it a test when you have a chance and let me know if it works for you. Install this branch with:

devtools::install_github("EDIorg/EMLassemblyline", ref = "121-geocov-sitecol")

RobLBaker commented 1 year ago

Seems to work great, thanks!

clnsmth commented 1 year ago

Thanks again @RobLBaker. This fix has been merged into the master branch.