This function checks that the given reporter code is valid. If the code is not valid, the function throws an error message indicating which codes are invalid. It also converts the input to a proper format if necessary.
Arguments
- reporter
A character vector or string of comma-separated codes that represent the reporters in the trade data. The default value is NULL.
Examples
if (FALSE) { # interactive()
check_reporterCode("USA")
check_reporterCode(c("USA", "FRA"))
check_reporterCode("all")
}