CHMT: This function avoids double counting of China
Description
We assume that if the pre-aggregates exists then the
individual level are present. This function should only
used when performing aggregation.
Usage
CHMT(var, data, year = "Year")
Arguments
var
The variables that require to be sanitized.
data
The data frame which contains the data
year
The column which correspond to the year.
Details
We decide to use the smaller subsets in the regional
level because weighting variable may not exist for other
variables for the larger subsets.
The function only work for FAOST_CODE, if the country
coding system is not in FAOST_CODE then use the
translateCountryCode function to translate it.