| Encoding: | UTF-8 | 
| Type: | Package | 
| Title: | Convert Vietnam Provincial Codes | 
| Version: | 0.1.1 | 
| Maintainer: | Anh Le <anh.le@duke.edu> | 
| Description: | Converts Vietnam's provinces' names and ID across different formats. Handles diacritics and different spellings. | 
| Depends: | R (≥ 3.1.0) | 
| License: | GPL-3 | 
| LazyData: | TRUE | 
| RoxygenNote: | 5.0.1 | 
| Suggests: | testthat | 
| NeedsCompilation: | no | 
| Packaged: | 2016-07-07 17:55:57 UTC; anh | 
| Author: | Anh Le [aut, cre] | 
| Repository: | CRAN | 
| Date/Publication: | 2016-07-07 20:24:13 | 
Convert Vietnam provincial ID
Description
Converts Vietnam's provinces' names and ID across different formats. Handles diacritics and different spellings.
Usage
vietnamcode(sourcevar, origin = c("province_name", "enterprise_census",
  "enterprise_census_old", "enterprise_census_c", "pci"),
  destination = c("province_name", "province_name_diacritics",
  "enterprise_census", "enterprise_census_old", "enterprise_census_c", "pci"))
Arguments
sourcevar | 
 Character vector that contains the codes or province names to be converted  | 
origin | 
 String that indicates the coding scheme of origin  | 
destination | 
 String that indicates the coding scheme of destination  | 
Note
Supports the following coding schemes:
province_name
province_name_diacritics
enterprise_censusm enterprise_census_old, enterprise_census_c: the same as GSO code
pci: Provincial Competitiveness Index
Examples
codes.of.origin <- vietnamcode::vietnamcode_data$province_name # Vector of values to be converted
vietnamcode(codes.of.origin, "province_name", "pci")
Vietnam provinces ID
Description
Vietnam provinces ID
Usage
vietnamcode_data
Format
A data frame
province_nameprovince name
province_nameprovince name with diacritics
pciused by the Provincial Competitiveness Index
enterprise_censusused by the General Statistics Office (GSO) for the Enterprise Census
enterprise_census_oldold GSO code
enterprise_census_cGSO code as character
regexRegular Expression to match different spellings