Description Usage Arguments Value Examples
Perform a decomposition of value change using price and quantity indicators. This is an additive decomposition so that change due to price plus change due to quantity equals the total value change.
1 2 3 4 5 6 7 8 9 | valueDecomposition(
x,
pvar,
qvar,
pervar,
prodID,
priceMethod,
sample = "matched"
)
|
x |
data frame with input data |
pvar |
character string for the name of the price column |
qvar |
character string for the name of the quantity column |
pervar |
character string for the name of the time period variable |
prodID |
character string for the name of the product ID column |
priceMethod |
character string for the price indicator method. Valid options are "laspeyres", "paasche", "bennet", or "montgomery". This parameter also determines the method used for the quantity indicator. If a laspeyres price indicator is chosen, then a paasche quantity indicator is used. If a paasche price indicator is used then a laspeyres quantity indicator is used. For bennet and montgomery indicators, the same method is used for both the price and quantity indicators. |
sample |
whether to use a matched sample (sample = "matched") |
a dataframe containing the price indicator, quantity indicator the value change and the value level.
1 2 3 | # decompose the value changes in the CES_sigma_2 dataset using the Bennet method
valueDecomposition(CES_sigma_2, pvar = "prices", qvar = "quantities",
prodID = "prodID", pervar = "time", priceMethod = "bennet")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.