R/csv_to_adm2pop.R

#' Cleans UN WPP interpolated to single age group data then subsets to desired ISO's and then populates adm2 locations
#' @param xls_location File location of csv document.
#' @param countryiso This is a vector of the ISO codes for all countries you want to generate populations for.
#' @examples
#' csv_to_adm2pop("AGO")
#' @export 



csv_to_adm2pop<-function(countryiso){
  
  #Clean wpp_int
  print("Cleaning WPP csv")
  cleanwpp_int<-csv_clean(countryiso)
  
  #Populate adm2 locations with cleanwpp_int
  print("Population adm2 locations with cleaned WPP dataframe")
  finished<-popperadm2(cleanwpp_int)
  
  #Done
  print("Done")
  finished

}
arranhamlet/popvac_package documentation built on May 10, 2019, 1:48 p.m.