Description Usage Arguments Value
This function takes SUA level data and standardizes up the required production values for processed commodities into a food value for their parents. The idea is that we have official and estimated data at the SUA level, and the imbalances at this level translate into an imbalance in their parent commodities. To capture/account for this imbalance, we roll it up into food at the top line. Note that the original estimates for food will be stored in this table under a new element code: the current food element code pasted with "_orig". These original values need to be saved somewhere, and this seemed like a reasonable place.
1 | rollUpFood(data, tree, standParams)
|
data |
The data.table containing the full dataset for standardization. |
tree |
The commodity tree which provides the edge structure. |
standParams |
The parameters for standardization. These parameters provide information about the columns of data and tree, specifying (for example) which columns should be standardized, which columns represent parents/children, etc. |
The same data.table as was passed ("data") but with updated food distributions to account for standardized production of children commodities.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.