tradestatistics (version 1.1)

ots_product_code: String matching of official product names and Harmonized System (HS) codes according to the United Nations nomenclature

Description

Takes a text string and searches within the package data for all matching product codes in the context of valid API product codes.

Usage

ots_product_code(productname = NULL, productgroup = NULL)

Arguments

productname

A text string such as "Animals", "COPPER" or "fruits".

productgroup

A text string such as "meat", "FISH" or "Dairy".

Value

A tibble with all possible matches (no uppercase distinction) showing the product name and product code

Examples

Run this code
# NOT RUN {
ots_product_code(productname = "ANIMALS ")
ots_product_code(productgroup = "  fish")
ots_product_code(productname = "Milk", productgroup = "Dairy")
# }

Run the code above in your browser using DataLab