-
Notifications
You must be signed in to change notification settings - Fork 53
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
Feature Request: Add numeric decodes for COUNTRY #2388
Comments
This seems like a good idea for implementation. I wonder though ifi would be better to store the country codes in a small dataset provided with the package? |
This gets a bit in the realm of metadata. We've always tried to shy away from getting to much into that...but we have exceptions like lab grading. How come this can't be fed in via a spec sheet and make use of metatools? Maybe a cool example for the examples site? @pharmaverse/admiral and @pharmaverse/admiral_comm What do you think? |
@bms63 it would definitely be a candidate for |
* Add country_code_lookup * Add country_code_lookup * Update country_code_lookup and NEWS * Run styler * Add test file * Update codes and test * Update NEWS.md Co-authored-by: Edoardo Mancini <53403957+manciniedoardo@users.noreply.github.com> * Update R/create_country_codes.R Co-authored-by: Edoardo Mancini <53403957+manciniedoardo@users.noreply.github.com> * Run styler on vignette and update Turkey name for non ascii characters * Update documentation * Remove non-ascii characters * Calculate number by order * Update NEWS.md Co-authored-by: Stefan Bundfuss <80953585+bundfussr@users.noreply.github.com> * Doc: #2388 Remove extra #' --------- Co-authored-by: Jeffrey Dickinson <dickinson.jeffrey@gene.com> Co-authored-by: Edoardo Mancini <53403957+manciniedoardo@users.noreply.github.com> Co-authored-by: Ben Straub <ben.x.straub@gsk.com> Co-authored-by: Stefan Bundfuss <80953585+bundfussr@users.noreply.github.com>
Feature Idea
ADPPK
(Population PK) requires numeric decodes for covariates.COUNTRYN
is the numeric decoded version ofCOUNTRY
. Sometimes the list of decodes can be very long for large studies. One option that some sponsors may use is to use a number based on the ISO 3166-1 alpha-3 codes.For example:
Set to the country [ADSL.COUNTRY] using the code list which assigns the numerical representation of the standard-defined 249 countries after alphabetical sorting.
1 = ABW (ARUBA)
2 = AFG (AFGHANISTAN)
3 = AGO (ANGOLA)
…
The 249 3-letter codes correspond to the ISO 3166-1 alpha-3 codes:
https://en.wikipedia.org/wiki/ISO_3166-1_alpha-3
The decodes could be stored in function as below or in a tibble.
Relevant Input
No response
Relevant Output
No response
Reproducible Example/Pseudo Code
No response
The text was updated successfully, but these errors were encountered: