CJ Yetman
CJ Yetman
Not sure when I'll have time to review this in depth, but... I was just pondering something like this recently... having a separate lookup table for each possible origin-destination pair....
1. I would definitely prefer to **not** go from 0 dependencies to 4. 2. I think this might conflict with custom dictionaries where we won't know the names of the...
I had to jump through hoops to get around the merge conflicts, but in my quick test of this PR, `countrycode(c('USA', 'DZA'))` returns a vector with NAs and warnings, which...
I could probably help with that here and/or in [rworldmap](https://github.com/AndySouth/rworldmap) [countrycode repo is here](https://github.com/vincentarelbundock/countrycode) @vincentarelbundock is the maintainer
I back that. The compressed `codelist.rda` file is only 242 KB with 288 rows × 621 columns, and presumably most of these custom dictionaries would be much, much smaller.
Since {countrycode} does include CLDR names in Chinese, one could (rather easily) create a custom dictionary using the included `codelist` to achieve *exact* matching, though it will not do fancy...
@turbanisch this is really cool, thanks for all your effort so far just a suggestion if/when you start building a PR... I would suggest following the model of adding known...
Similarly, `readr::parse_number()` doesn't parse as expected when the `grouping_mark` is a multi-byte character... ``` r mark [1] 20 txt [1] "123 456.78" readr::parse_number(txt, locale = readr::locale(grouping_mark = mark)) #> [1]...
> Place to start is probably to figure out what's going on here: > > ```r > library(readr) > > parse_number("123--456", locale = locale(grouping_mark = "--")) > #> [1] 123456...
pretty sure this is iterating through bytes, not characters https://github.com/tidyverse/readr/blob/e529cb2775f1b52a0dfa30dabc9f8e0014aa77e6/src/parse.cpp#L165-L178